VR-Forces Developer's Guide
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
List of all members | Public Member Functions | Static Public Member Functions | Protected Member Functions | Protected Attributes
DtRwPropertiesStructure Class Reference

A structure composed of distinct fields, each of which is itself a property. The DtRwPropertiesStructure is composed of multiple component properties that function as fields to a structure, similar to a structure in C++. Each field is itself a property. This class provides functions to easily find and access the fields within the property.

Inheritance diagram for DtRwPropertiesStructure:
Inheritance graph
[legend]

Public Member Functions

 DtRwPropertiesStructure ()
 
 DtRwPropertiesStructure (const DtString &name, DtReaderWriterRegistry *parentRegistry=0)
 
 DtRwPropertiesStructure (const DtString &name, const DtRwPropertiesStructure &orig, DtReaderWriterRegistry *parentRegistry=0)
 
 DtRwPropertiesStructure (const DtRwPropertiesStructure &orig, DtReaderWriterRegistry *parentRegistry=0)
 
DtRwPropertiesStructureoperator= (const DtRwPropertiesStructure &orig)
 
virtual ~DtRwPropertiesStructure () override
 
virtual void putSelf (std::string &fp, int indentLevel, bool writeUnspecified, const DtFilename &path) override
 
virtual const charreaderWriterType () const override
 
virtual const charxmlType () const override
 
virtual void copyVariables (const DtRwVariableBindings &other) override
 
virtual bool isSimilarProperty (const DtPropertyInterface *rhs, bool strict=true) const override
 
Generic field lookup functions

These functions return the DtPropertyInterface for the named field, assuming it is found within this structure. If this field cannot be found, a null pointer is returned. Because fields are themselves just properties, this is just a wrapper for DtRwProperties::findPropertyInterface.

const DtPropertyInterfacefindFieldPropertyInterface (const DtString &fieldName) const
 
DtPropertyInterfacefindFieldPropertyInterface (const DtString &fieldName)
 
Specific field type lookup functions

These functions return the specific property type for the named field, assuming it is found within this property and matches this type. If this field cannot be found or is of the wrong type, a null pointer is returned. Because fields are themselves just properties, this is just a wrapper for DtRwProperties::findProperty.

template<typename SpecificPropType >
const SpecificPropType * findField (const DtString &fieldName) const
 
template<typename SpecificPropType >
SpecificPropType * findField (const DtString &fieldName)
 
Convenience functions for finding and getting/setting field value
template<typename ValueType >
boost::optional< ValueType > findFieldValue (const DtString &fieldName) const
 
template<typename ValueType >
bool findAndSetFieldValue (const DtString &fieldName, ValueType val)
 
Field addition functions

These functions can be used to add new properties as fields to a structure.

virtual bool addField (DtPropertyInterface *field)
 
template<typename SpecificPropType >
SpecificPropType * addNewField (const DtString &fieldName)
 
Field removal functions

These functions can be used to remove fields from a structure. Returns true if successful. Because fields are themselves just properties, this is just a wrapper for DtRwPropertiesStructure::removeProperty.

virtual bool removeField (const DtString &propertyName)
 
virtual bool removeField (const DtPropertyInterface *property)
 
Overloads for operator[]

These operator[] overloads allow you to access a fields by their name. If the field does not exist, an uninitialized property will be returned that is not part of the structure, so care must be taken. Should only be used for known fields, not to add new ones. boost::optional<DtString> vehicleType = vehicleProperty["Vehicle Type"].propertyValue<DtString>(); vehicleProperty["Fuel Amount"].setPropertyValue<double>(12.5);

DtPropertyInterfaceoperator[] (const DtString &fieldName)
 
const DtPropertyInterfaceoperator[] (const DtString &fieldName) const
 
- Public Member Functions inherited from DtRwProperties
DtRwPropertiesoperator= (const DtRwProperties &orig)
 
virtual ~DtRwProperties () override
 
virtual unsigned size () const
 
virtual bool addProperty (DtPropertyInterface *) override
 
virtual bool addPropertyAtIndex (DtPropertyInterface *, unsigned index)
 
virtual void copy (const DtPropertyInterface &rhs) override
 
virtual void getSelf (DtlObjPtr args, const DtReaderWriter::SearchPaths &searchPaths=SearchPaths(), const DtVariableBindingsList &variableBindings=nullVariableReference()) override
 
virtual DtlObjPtr getData (DtlObjPtr args, const DtReaderWriter::SearchPaths &searchPaths=SearchPaths(), const DtVariableBindingsList &variableBindings=nullVariableReference()) override
 
virtual bool isValidProperty (const DtPropertyInterface *) const
 
virtual DtPropertyInterfacecreateProperty (DtlObjPtr args, DtReaderWriterRegistry *parentRegistry)
 
virtual charencode (char *) const override
 
virtual const chardecode (const char *) override
 
virtual void getSize (int &size) const override
 
virtual bool isReadonly () const
 
virtual int hlaAlignment () const override
 
virtual int requiredPadding (const char *buf, const DtPropertyInterface *field) const
 
virtual const charpropertyType () const override
 
virtual int count () const
 
virtual DtString stringRep (const DtString &root="") const override
 
virtual bool merge (const DtPropertyInterface &target, MergeFlags, const DtMergePath &path=DtMergePath(), const std::set< DtString > &ignore=std::set< DtString >()) override
 
virtual DtRwProperties createFromPercentages (const DtRwProperties &percentages, const DtRwProperties &baseValues, const DtString &base="Base-")
 
virtual bool findRootAndVariable (const DtString &varName, DtReaderWriter *&root, DtReaderWriter *&variable) const
 
virtual DtSymbolString propertyName () const override
 
virtual void setPropertyName (const DtString &propertyName) override
 
virtual bool isUpdateNeeded (DtTime t) const override
 
virtual bool hasReceivedUpdateSince (DtTime t) const override
 
virtual DtTime updateClockTime () const override
 
virtual void clearVariables () override
 
virtual void reset () override
 
virtual void invalidateCache ()
 
virtual void invalidateCacheForProperty (const DtString &propName)
 
virtual bool setWritePrototypeHeader (bool)
 
virtual bool writePrototypeHeader () const
 
virtual void cloneAndAddProperty (const DtReaderWriter &rw)
 
virtual void setKeepPublishingSettings (bool keep) override
 
virtual bool keepPublishingSettings () const override
 
 DtRwProperties (const DtString &name, DtReaderWriterRegistry *parentRegistry=0)
 
 DtRwProperties (const DtString &name, const DtRwProperties &orig, DtReaderWriterRegistry *parentRegistry=0)
 
 DtRwProperties (const DtRwProperties &orig, DtReaderWriterRegistry *parentRegistry=0)
 
virtual const_iterator begin () const
 
virtual iterator begin ()
 
virtual const_iterator end () const
 
virtual iterator end ()
 
virtual const DtPropertyInterfacefindPropertyInterface (const DtString &propertyName) const override
 
virtual DtPropertyInterfacefindPropertyInterface (const DtString &propertyName) override
 
virtual bool removeProperty (const DtString &propertyName) override
 
virtual bool removeProperty (const DtPropertyInterface *property) override
 
virtual const DtReaderWriterfindPropertyRw (const DtString &propName) const
 
virtual DtReaderWriterfindPropertyRw (const DtString &propName)
 
virtual DtReaderWriterreaderWriter () override
 
virtual const DtReaderWriterreaderWriter () const override
 
virtual DtPropertyInterfaceproperty () override
 
virtual const DtPropertyInterfaceproperty () const override
 
virtual bool isPublished () const override
 
virtual void setIsPublished (bool isPub) override
 
virtual unsigned disRecordType () const override
 
virtual void setDisRecordType (unsigned recType) override
 
virtual void removeVariable (DtReaderWriter *) override
 
virtual void removeVariable (const DtReaderWriter *) override
 
- Public Member Functions inherited from DtRwVariableBindings
 DtRwVariableBindings (const DtString &name, DtReaderWriterRegistry *parentRegistry=0)
 
 DtRwVariableBindings (const DtString &name, const DtRwVariableBindings &orig, DtReaderWriterRegistry *parentRegistry=0, bool copyVariables=true)
 
 DtRwVariableBindings (const DtRwVariableBindings &orig, DtReaderWriterRegistry *parentRegistry=0, bool copyVariables=true)
 
DtRwVariableBindingsoperator= (const DtRwVariableBindings &orig)
 
virtual ~DtRwVariableBindings () override
 
template<typename RW_Type >
const RW_Type * findAndCastVariableBinding (const DtString &variableName) const
 
virtual DtReaderWriteraddVariableBinding (const DtSymbolString &name, const char *type)
 
virtual void addVariable (DtReaderWriter *)
 
virtual int getSize () const
 
bool operator== (const DtRwVariableBindings &) const
 
bool operator!= (const DtRwVariableBindings &) const
 
virtual DtString prettyPrint () const override
 
virtual void setVariableSubstitutions (const std::map< DtString, DtString > &)
 
virtual const std::map
< DtString, DtString > & 
variableSubstitutions () const
 
virtual void merge (const DtRwVariableBindings &)
 
virtual const DtReaderWriterfindVariableBinding (const DtString &rwTypeString, const DtString &variableName, const std::map< DtString, DtString > &variableSubstitutions=std::map< DtString, DtString >()) const
 
virtual DtReaderWriterfindVariableBinding (const DtString &rwTypeString, const DtString &variableName, const std::map< DtString, DtString > &variableSubstitutions=std::map< DtString, DtString >())
 
virtual const DtReaderWriterfindVariableBinding (const DtString &variableName, const std::map< DtString, DtString > &variableSubstitutions=std::map< DtString, DtString >()) const
 
virtual DtReaderWriterfindVariableBinding (const DtString &variableName, const std::map< DtString, DtString > &variableSubstitutions=std::map< DtString, DtString >())
 
- Public Member Functions inherited from DtReaderWriter
 DtReaderWriter ()
 
 DtReaderWriter (const DtString &name, DtReaderWriterRegistry *parentRegistry=NULL, bool readonly=false)
 
 DtReaderWriter (const DtSymbolString &name, DtReaderWriterRegistry *parentRegistry=NULL, bool readonly=false)
 
 DtReaderWriter (const DtString &name, const DtReaderWriter &orig, DtReaderWriterRegistry *parentRegistry=NULL)
 
 DtReaderWriter (const DtSymbolString &name, const DtReaderWriter &orig, DtReaderWriterRegistry *parentRegistry=NULL)
 
 DtReaderWriter (const DtReaderWriter &, DtReaderWriterRegistry *parentRegistry=NULL)
 
const DtReaderWriteroperator= (const DtReaderWriter &orig)
 
bool operator== (const DtReaderWriter &) const
 
bool operator!= (const DtReaderWriter &rhs) const
 
virtual ~DtReaderWriter ()
 
virtual void postPutSelf ()
 
virtual void prePutSelf ()
 
virtual void postGetSelf ()
 
virtual void preGetSelf ()
 
virtual DtSymbolString name () const
 
virtual void addAlias (const DtSymbolString &alias)
 
virtual void addAlias (const DtString &alias)
 
virtual bool hasAlias (const DtSymbolString &alias)
 
virtual const aliasContaineraliases () const
 
virtual void setReadonly (bool flag)
 
bool isReadonly () const
 
virtual int alignment () const
 
virtual bool variableIsBound () const
 
virtual void unbindVariable ()
 
virtual void setName (const DtString &)
 
std::string debugText () const
 
virtual void bindVariables (DtVariableBindingsList variableBindings)
 
virtual std::list
< DtVariableNameType
unboundVariables () const
 
bool invalid () const
 
virtual bool hasChild (const DtReaderWriter *p) const
 
virtual bool hasVariableReference () const
 
virtual void bindLocalVariables (const DtVariableBindingsList &variableBindings)
 
virtual void recordUpdateTime () const
 
virtual bool changedSinceLastChecked ()
 
virtual bool peekChangedSinceLastChecked () const
 
virtual void setValueSpecified (bool specified, bool recurse=false)
 
virtual bool valueSpecified () const
 
virtual bool isVariableReference () const
 
virtual void setIsVariableReference (bool value)
 
virtual void clearAllVariableReferenceFlags ()
 
virtual DtSymbolString variableName () const
 
virtual void setVariableName (const DtSymbolString variableName)
 
virtual const DtReaderWriterdefaultRWValue () const
 
virtual DtReaderWriterdefaultRWValue ()
 
virtual void setDefaultRWValue (DtReaderWriter *)
 
virtual bool checkAndSetDefaultRWValue (DtlObjPtr args, const DtReaderWriter::SearchPaths &searchPaths=SearchPaths(), const DtVariableBindingsList &variableBindings=nullVariableReference())
 
const DtReaderWriterRegistryregistry () const
 
DtReaderWriterRegistryregistry ()
 
virtual DtString toXml () const
 
virtual DtRwVariableBindingsgenerateVariableBindings () const
 
virtual bool toXml (const DtFilename &) const
 
virtual bool fromXml (const DtString &)
 
virtual bool fromXmlFile (const DtFilename &)
 
virtual void putSelf (DtEnvironmentSP, DtEnvValueSP parent) const
 
virtual void putVariableReference (DtEnvironmentSP, DtEnvValueSP value) const
 
virtual void getSelf (const DtEnvironmentSP, const DtEnvValueSP root, const SearchPaths &searchPaths=SearchPaths(), const DtVariableBindingsList &bindings=DtVariableBindingsList())
 
virtual void getVariableReference (DtEnvironmentSP, DtEnvValueSP value)
 
- Public Member Functions inherited from DtPropertyInterface
virtual ~DtPropertyInterface ()
 
virtual bool isPublishedArg (DtlObjPtr arg, unsigned &disVarRecType)
 
virtual void copyPublishingSettings (const DtPropertyInterface &prop)
 
virtual void processPublicationArgs (DtlObjPtr arg)
 
virtual void processPublicationArg (DtlObjPtr arg)
 
template<typename ValueType >
boost::optional< ValueType > propertyValue () const
 
template<typename ValueType >
bool setPropertyValue (ValueType val)
 
template<typename SpecificPropType >
const SpecificPropType * findProperty (const DtString &propertyName) const
 
template<typename SpecificPropType >
SpecificPropType * findProperty (const DtString &propertyName)
 
template<typename ValueType >
boost::optional< ValueType > findPropertyValue (const DtString &propertyName) const
 
template<typename ValueType >
bool findAndSetPropertyValue (const DtString &propertyName, ValueType val)
 
template<typename SpecificPropType >
SpecificPropType * addNewProperty (const DtString &propertyName)
 
int getSize () const
 

Static Public Member Functions

static const chartheXmlType ()
 
- Static Public Member Functions inherited from DtRwProperties
static
DtReaderWriterPropertyFactory
propertyFactory ()
 
static void cleanupPropertyFactory ()
 
static const DtRwPropertiesemptyProperties ()
 
static bool rollUpInteger (const DtReaderWriter *source, DtReaderWriter *destination, const DtMergePath &path)
 
static bool rollUpReal (const DtReaderWriter *source, DtReaderWriter *destination, const DtMergePath &path)
 
static bool rollUpString (const DtReaderWriter *source, DtReaderWriter *destination, const DtMergePath &path)
 
static bool rollUpBoolean (const DtReaderWriter *source, DtReaderWriter *destination, const DtMergePath &path)
 
- Static Public Member Functions inherited from DtRwVariableBindings
static DtRwVariableBindingscreateBinding (const std::list< DtReaderWriter::DtVariableNameType > &)
 
- Static Public Member Functions inherited from DtReaderWriter
static void putIndent (std::string &fp, int indentLevel)
 
static const
DtVariableBindingsList
nullVariableReference ()
 
static void setPostGetSelfCallback (DtGetSelfCallbackFcn fcn, void *usrData)
 
static void setPrePutSelfCallback (DtPutSelfCallbackFcn fcn, void *usrData)
 
static void setPutIndent (bool)
 
static bool putIndent ()
 
static const chartheXmlType ()
 
static const DtFilename & appPath ()
 
static void setFactoryCreatorFunction (DtReaderWriterFactoryCreatorFcn fcn)
 
static void createReaderWriterFactory ()
 
static void cleanupFactory ()
 
static DtReaderWriterFactoryfactory ()
 
static void setOutputStream (DtOutputStream *stream)
 
static DtOutputStream & outputStream ()
 
static DtReaderWritercreateFromXmlFile (const DtFilename &, bool createAsProperty=false)
 
static DtReaderWritercreateFromXml (const DtString &, bool createAsProperty=false)
 
static DtReaderWritercreateFromEnvironment (DtEnvironmentSP, bool createAsProperty=false)
 
static DtString getAttribute (DtEnvironmentSP env, const DtString &name, DtEnvValueSP root)
 

Protected Member Functions

virtual void getData (const DtEnvironmentSP env, const DtEnvValueSP root, const DtReaderWriter::SearchPaths &searchPaths, const DtVariableBindingsList &varBindings) override
 
virtual void putData (DtEnvironmentSP, DtEnvValueSP value) const override
 
- Protected Member Functions inherited from DtRwProperties
virtual void filterIgnoredProperties (DtReaderWriter *rw, const std::set< DtString > &ignore)
 
virtual void getInterface (DtPropertyInterface *pFace, DtlObjPtr args, const DtReaderWriter::SearchPaths &searchPaths=SearchPaths(), const DtVariableBindingsList &variableBindings=nullVariableReference())
 
virtual void writeSelf (std::string &fp, int indentLevel, bool writeUnspecified, const DtFilename &path) override
 
virtual void writeData (std::string &fp, int indentLevel, bool writeUnspecified, const DtFilename &path)
 
virtual void putData (std::string &, int indentLevel=0) override
 
virtual int hlaAlignment (const DtPropertyInterface *field) const
 
virtual void getSize (const DtPropertyInterface *, int &size) const
 
virtual charencode (const DtPropertyInterface *, char *buf) const
 
virtual const chardecode (DtPropertyInterface *iFace, const char *buf)
 
virtual void unrecognizedItem (const DtEnvironmentSP env, const DtEnvValueSP root, const DtReaderWriter::SearchPaths &searchPaths, const DtVariableBindingsList &varBindings) override
 
virtual bool traverseAndModifyPercentage (DtRwProperties &results, const DtRwProperties &baseValues, const DtReaderWriter *percentage, const DtString &base) const
 
virtual void writePrototypeHeader (std::string &fp, const DtReaderWriter *rw, int indentLevel) const
 
virtual void writePropertyData (DtReaderWriter *rw, std::string &fp, int indentLevel, bool writeUnspecified, const DtFilename &path)
 
virtual void writePublishInformation (std::string &fp, int indentLevel) override
 
virtual void getSortedProperties (const DtRwVariableBindings &varBindings, std::vector< const DtReaderWriter * > &propertyList) const
 
virtual void getSortedProperties (DtRwVariableBindings &varBindings, std::vector< DtReaderWriter * > &propertyList)
 
virtual bool isDebugEnabled () const override
 
virtual void setDebugEnabled (bool en) override
 
- Protected Member Functions inherited from DtRwVariableBindings
virtual const DtReaderWriterinternalFindVariableBinding (const DtString &rwTypeString, const DtString &variableName, const std::map< DtString, DtString > &variableSubstitutions=std::map< DtString, DtString >()) const
 
virtual bool keywordMatches (const DtSymbolString &lhs, const DtString &rhs, const std::map< DtString, DtString > &variableSubstitutions) const
 
- Protected Member Functions inherited from DtReaderWriter
virtual void bindToRwAsVariable (const DtReaderWriter *rw)
 

Protected Attributes

DtPropertyInterfacemyScratchItem
 
- Protected Attributes inherited from DtRwProperties
std::multimap< DtString,
DtReaderWriter * > 
myRwPropertyCache
 
tbb::spin_mutex * myCacheMutex
 
DtClock myClock
 
DtTime myLastTimeSizeChanged
 
int mySizeAtLastCheck
 
unsigned myDisRecordType
 
bool myIsPublished
 
bool myWritePrototypeHeader
 
bool myDebugEnabled
 
bool myKeepPublishingSettingsOnCopy
 
DtPropertyInterfacemyPreviousParentProp
 
DtString myPreviousParentPropFullName
 
- Protected Attributes inherited from DtRwVariableBindings
std::map< DtString, DtStringmyVariableSubstitutions
 
- Protected Attributes inherited from DtReaderWriter
const DtSymbolString myName
 
DtReaderWriterRegistry myRegistry
 
DtReaderWriterRegistrymyParentRegistry
 
bool myValueSpecified
 
bool myReadOnlyFlag
 
bool myIsVariableReference
 
DtSymbolString myVariableName
 
bool myVariableIsBound
 
DtReaderWritermyDefaultValue
 
aliasContainer myAliases
 
bool myInvalid
 
bool myChangedFlag
 

Additional Inherited Members

- Public Types inherited from DtRwProperties
typedef DtPropertiesIterator iterator
 
typedef DtPropertiesConstIterator const_iterator
 
- Public Types inherited from DtReaderWriter
typedef std::vector
< DtSymbolString
aliasContainer
 
typedef std::vector
< DtSymbolString >::iterator 
aliasIter
 
typedef std::vector
< DtSymbolString >
::const_iterator 
aliasConstIter
 
typedef std::vector< DtFilename > SearchPaths
 
typedef std::pair
< DtSymbolString, DtString
DtVariableNameType
 
typedef DtReaderWriterFactory *(* DtReaderWriterFactoryCreatorFcn )()
 
- Public Types inherited from DtPropertyInterface
enum  MergeFlags {
  Replace = 0x00000001, MinimalSimilarityCheck = 0x00000002, RollUp = 0x00000004, AddMissing = 0x00000008,
  KeepPublishedSettings = 0x00000010
}
 
- Static Protected Attributes inherited from DtRwProperties
static
DtReaderWriterPropertyFactory
thePropertyFactory
 
- Static Protected Attributes inherited from DtReaderWriter
static DtString theUnspecifiedValue
 
static DtGetSelfCallbackInfo thePostGetSelfCallback
 
static DtPutSelfCallbackInfo thePrePutSelfCallback
 
static const DtVariableBindingsList theEmptyVariableBindingsList
 
static bool theCreatorFcnSet
 
static DtReaderWriterFactorytheFactory
 
static
DtReaderWriterFactoryCreatorFcn 
theFactoryCreatorFcn
 
static bool thePutIndent
 
static DtOutputStream * theOutputStream
 

Constructor & Destructor Documentation

DtRwPropertiesStructure::DtRwPropertiesStructure ( )
DtRwPropertiesStructure::DtRwPropertiesStructure ( const DtString name,
DtReaderWriterRegistry parentRegistry = 0 
)
DtRwPropertiesStructure::DtRwPropertiesStructure ( const DtString name,
const DtRwPropertiesStructure orig,
DtReaderWriterRegistry parentRegistry = 0 
)
DtRwPropertiesStructure::DtRwPropertiesStructure ( const DtRwPropertiesStructure orig,
DtReaderWriterRegistry parentRegistry = 0 
)
virtual DtRwPropertiesStructure::~DtRwPropertiesStructure ( )
overridevirtual

Member Function Documentation

DtRwPropertiesStructure& DtRwPropertiesStructure::operator= ( const DtRwPropertiesStructure orig)
const DtPropertyInterface* DtRwPropertiesStructure::findFieldPropertyInterface ( const DtString fieldName) const
inline
DtPropertyInterface* DtRwPropertiesStructure::findFieldPropertyInterface ( const DtString fieldName)
inline
template<typename SpecificPropType >
const SpecificPropType* DtRwPropertiesStructure::findField ( const DtString fieldName) const
inline
template<typename SpecificPropType >
SpecificPropType* DtRwPropertiesStructure::findField ( const DtString fieldName)
inline
template<typename ValueType >
boost::optional<ValueType> DtRwPropertiesStructure::findFieldValue ( const DtString fieldName) const
inline

This is a convenience function that combines the functionality of findField and propertyValue to immediately return the value of the field with the given name, assuming it can be found within this property and its value can be converted to the specified type. If not, the boost::optional will be false. Because fields are themselves just properties, this is just a wrapper for DtRwProperties::findPropertyValue.

template<typename ValueType >
bool DtRwPropertiesStructure::findAndSetFieldValue ( const DtString fieldName,
ValueType  val 
)
inline

This is a convenience function that combines the functionality of findField and setPropertyValue to immediately set the value of the field with the given name, assuming it can be found within this property and its value can be converted from the specified type. If successful, returns true, otherwise returns false. Because fields are themselves just properties, this is just a wrapper for DtRwProperties::findPropertyValue.

virtual bool DtRwPropertiesStructure::addField ( DtPropertyInterface field)
inlinevirtual

Adds an existing property as a field to the structure. The structure will take ownership of the given property. Returns false if this operation was not possible. Because fields are themselves just properties, this is just a wrapper for DtRwPropertiesStructure::addProperty.

References DtRwProperties::addProperty().

template<typename SpecificPropType >
SpecificPropType* DtRwPropertiesStructure::addNewField ( const DtString fieldName)
inline

Adds a new property of the specified type as a field to the structure and returns pointer to the new item. Returns a null pointer if a field with that name already existed. Because fields are themselves just properties, this is just a wrapper for DtRwPropertiesStructure::addNewProperty.

virtual bool DtRwPropertiesStructure::removeField ( const DtString propertyName)
inlinevirtual
virtual bool DtRwPropertiesStructure::removeField ( const DtPropertyInterface property)
inlinevirtual
DtPropertyInterface& DtRwPropertiesStructure::operator[] ( const DtString fieldName)
const DtPropertyInterface& DtRwPropertiesStructure::operator[] ( const DtString fieldName) const
virtual void DtRwPropertiesStructure::putSelf ( std::string &  fp,
int  indentLevel,
bool  writeUnspecified,
const DtFilename &  path 
)
overridevirtual

Top level call to write itself to file. If write unspecified is true, will write entries that are unspecified, in the format (name <use-default>). Path is passed down to all DtReaderWriter members in its DtReaderWriterRegistry (collection of child DtReaderWriter nodes). If a given member in the registry is of type DtReaderWriterFile, and the path is specified with a non-NULL string, then the path prepended to the filename before writing the entry to file.

Reimplemented from DtReaderWriter.

virtual const char* DtRwPropertiesStructure::readerWriterType ( ) const
overridevirtual

Used to supply a string type that this reader writer type is. This can be used in place of dynamic-casting. Also used by the opd editor to determine which type of control to create.

Reimplemented from DtRwProperties.

static const char* DtRwPropertiesStructure::theXmlType ( )
static

The type that is used when archiving to an XML stream.

virtual const char* DtRwPropertiesStructure::xmlType ( ) const
inlineoverridevirtual

Reimplemented from DtReaderWriter.

References DtReaderWriter::theXmlType().

virtual void DtRwPropertiesStructure::copyVariables ( const DtRwVariableBindings other)
overridevirtual

Copies the values from the other structure.

Reimplemented from DtRwProperties.

virtual bool DtRwPropertiesStructure::isSimilarProperty ( const DtPropertyInterface rhs,
bool  strict = true 
) const
overridevirtual

Returns true if the readerWriterType and all registry items have the same readerWriter type.

Reimplemented from DtPropertyInterface.

virtual void DtRwPropertiesStructure::getData ( const DtEnvironmentSP  ,
const DtEnvValueSP  ,
const DtReaderWriter::SearchPaths searchPaths,
const DtVariableBindingsList bindings 
)
overrideprotectedvirtual

Gets data from the environment value.

Reimplemented from DtReaderWriter.

virtual void DtRwPropertiesStructure::putData ( DtEnvironmentSP  ,
DtEnvValueSP  value 
) const
overrideprotectedvirtual

Override to add attributes of actual data.

Reimplemented from DtReaderWriter.

Member Data Documentation

DtPropertyInterface* DtRwPropertiesStructure::myScratchItem
mutableprotected

The documentation for this class was generated from the following file:

Document ID: Generated on Thu Oct 23 22:29:17 EDT 2025 from SVN revision 280951
Copyright © 2005-2024 MAK Technologies. All Rights Reserved (www.mak.com)