VR-Forces 5.0.3 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 | Private Member Functions
DtRwPropertiesList Class Reference

Acts as a DtRwList for properties. Only real difference between this class and a DtRwProperties class is that items can have the same name and the encode/decode/getSelf add an integer at the beginning with is the number of elements in the list (int). The list must also be passed a homogeneous reader/writer type that will be used as the template for storing the items. During getSelf this template will be used as a means to read the default values, so, the mtl definition would look like:

(DtRwList HealthList DtRwReal 1.0 2.0 3.0)
or
(DtRwList CombatRange
(DtRwStruct CombatRange
(DtRwReal Range)
(DtRwInt Number)
)
(100.0 20) (200.0 40) (300.0 60)
)

As a subclass of DtRwProperties, DtRwPropertiesList supports an STL-like iterator for iterating over its items. It also has convenience functions for adding new items and erasing existing items by iterator. Because this list is designed to be accessed and set frequently by Lua, and the Lua API does not guarantee a particular ordering of items, a consistent order is also not guaranteed in C++.

Inheritance diagram for DtRwPropertiesList:
Inheritance graph
[legend]

Public Member Functions

virtual const charreaderWriterType () const
 
virtual const charxmlType () const
 
virtual charencode (char *) const
 
virtual const chardecode (const char *)
 
virtual void getSize (int &size) const
 
virtual int hlaAlignment () const
 
virtual bool isValidProperty (const DtPropertyInterface *) const
 
virtual int count () const
 
virtual void getSelf (DtlObjPtr args, const DtReaderWriter::SearchPaths &searchPaths=DtReaderWriter::SearchPaths(), const DtVariableBindingsList &variableBindings=nullVariableReference())
 
virtual void writeSelf (std::string &fp, int indentLevel=0, bool writeUnspecified=false, const DtFilename &path=DtFilename::nullFilename())
 
virtual void writeData (std::string &fp, int indentLevel=0, bool writeUnspecified=false, const DtFilename &path=DtFilename::nullFilename())
 
virtual void setPrototype (const DtPropertyInterface *)
 
virtual const DtPropertyInterfaceprototype () const
 
virtual DtPropertyInterfaceclonePrototype (DtReaderWriterRegistry *parent=0)
 
DtRwPropertiesListoperator= (const DtRwPropertiesList &)
 
virtual bool isSimilarProperty (const DtPropertyInterface *rhs, bool strict=true) const
 
bool operator== (const DtRwPropertiesList &) const
 
virtual bool matchPrototype (const DtReaderWriter *) const
 
Constructors
 DtRwPropertiesList (const DtString &name, DtReaderWriterRegistry *parentRegistry=0)
 
 DtRwPropertiesList (const DtString &name, const DtPropertyInterface *prototype, DtReaderWriterRegistry *parentRegistry=0)
 
 DtRwPropertiesList (const DtString &name, const DtRwPropertiesList &orig, DtReaderWriterRegistry *parentRegistry=0)
 
virtual ~DtRwPropertiesList ()
 
Add New Items

Adds a new item to the end of the list. Fails if the item's type does not match that of myPrototype, in which case it returns false. Takes ownership of the item.

DtRwPropertyInt* newItem = new DtRwPropertyInt("new-item", 4);
propertiesList.add(newItem);
virtual bool addItem (DtPropertyInterface *item)
 
virtual DtPropertyInterfaceaddItem ()
 
Erase Items

Erases the specified item.

virtual void erase (DtPropertyInterface *item)
 
virtual void erase (iterator pos)
 
- Public Member Functions inherited from DtRwProperties
DtRwPropertiesoperator= (const DtRwProperties &orig)
 
virtual ~DtRwProperties ()
 
virtual unsigned size () const
 
virtual bool addProperty (DtPropertyInterface *)
 
virtual bool addPropertyAtIndex (DtPropertyInterface *, unsigned index)
 
virtual void copy (const DtPropertyInterface &rhs)
 
virtual DtPropertyInterfacecreateProperty (DtlObjPtr args, DtReaderWriterRegistry *parentRegistry)
 
virtual void copyVariables (const DtRwVariableBindings &other)
 
virtual bool isReadonly () const
 
virtual int requiredPadding (const char *buf, const DtPropertyInterface *field) const
 
virtual const charpropertyType () const
 
virtual DtString stringRep (const DtString &root="") const
 
virtual bool merge (const DtPropertyInterface &target, MergeFlags, const DtMergePath &path=DtMergePath(), const std::set< DtString > &ignore=std::set< DtString >())
 
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
 
virtual void setPropertyName (const DtString &propertyName)
 
virtual bool wasUpdatedSince (DtTime t) const
 
virtual void clearVariables ()
 
virtual void reset ()
 
virtual void invalidateCache ()
 
virtual void invalidateCacheForProperty (const DtString &propName)
 
virtual bool setWritePrototypeHeader (bool)
 
virtual bool writePrototypeHeader () const
 
 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
 
virtual DtPropertyInterfacefindPropertyInterface (const DtString &propertyName)
 
virtual bool removeProperty (const DtString &propertyName)
 
virtual bool removeProperty (const DtPropertyInterface *property)
 
virtual const DtReaderWriterfindPropertyRw (const DtString &propName) const
 
virtual DtReaderWriterfindPropertyRw (const DtString &propName)
 
virtual DtReaderWriterreaderWriter ()
 
virtual const DtReaderWriterreaderWriter () const
 
virtual DtPropertyInterfaceproperty ()
 
virtual const DtPropertyInterfaceproperty () const
 
virtual bool isPublished () const
 
virtual void setIsPublished (bool isPub)
 
virtual unsigned disRecordType () const
 
virtual void setDisRecordType (unsigned recType)
 
virtual void removeVariable (DtReaderWriter *)
 
virtual void removeVariable (const DtReaderWriter *)
 
- 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 ()
 
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
 
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)
 
virtual ~DtReaderWriter ()
 
virtual void putSelf (std::string &fp, int indentLevel=0, bool writeUnspecified=false, const DtFilename &path=DtFilename::nullFilename())
 
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) const
 
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 writePrototype (const DtReaderWriter *, std::string &fp, int indentLevel, bool writeHeader=true) const
 
virtual void bindToRwAsVariable (const DtReaderWriter *rw)
 
virtual void createListEntry (DtPropertyInterface *iFace, DtlObjPtr variableItem, const DtReaderWriter::SearchPaths &searchPaths, const DtVariableBindingsList &variableBindings)
 
virtual DtPropertyInterfacecreatePrototype (DtlObjPtr)
 
virtual DtlObjPtr variablesStart (DtlObjPtr args) const
 
virtual const chardecode (DtPropertyInterface *, const char *)
 
virtual DtlObjPtr getData (DtlObjPtr variableList, const DtReaderWriter::SearchPaths &searchPaths, const DtVariableBindingsList &variableBindings)
 
virtual void getData (const DtEnvironmentSP env, const DtEnvValueSP root, const DtReaderWriter::SearchPaths &searchPaths, const DtVariableBindingsList &varBindings)
 
virtual void putData (DtEnvironmentSP, DtEnvValueSP value) const
 
virtual void assignPrototypeToChildren ()
 
virtual void setPrototypeIntoTarget (const DtPropertyInterface *prototype, DtReaderWriter *target)
 
virtual void postWriteItem (std::string &fp, DtReaderWriter *rw, int indentLevel)
 
virtual void preWriteItem (std::string &fp, DtReaderWriter *rw, int indentLevel)
 
virtual bool matchPrototype (const DtReaderWriter *prototype, const DtReaderWriter *match) const
 
virtual void cloneAndAddProperty (const DtReaderWriter &rw)
 
- 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 putData (std::string &, int indentLevel=0)
 
virtual int hlaAlignment (const DtPropertyInterface *field) const
 
virtual void getSize (const DtPropertyInterface *, int &size) const
 
virtual charencode (const DtPropertyInterface *, char *buf) const
 
virtual void unrecognizedItem (const DtEnvironmentSP env, const DtEnvValueSP root, const DtReaderWriter::SearchPaths &searchPaths, const DtVariableBindingsList &varBindings)
 
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 getSortedProperties (const DtRwVariableBindings &varBindings, std::vector< const DtReaderWriter * > &propertyList) const
 
virtual void getSortedProperties (DtRwVariableBindings &varBindings, std::vector< DtReaderWriter * > &propertyList)
 
virtual bool isDebugEnabled () const
 
virtual void setDebugEnabled (bool en)
 
- 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 Attributes

DtPropertyInterfacemyPrototype
 
DtRwPropertyInt myCount
 
- 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
 
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
 

Private Member Functions

 DtRwPropertiesList ()
 

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,
  KeepIsPublished = 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

DtRwPropertiesList::DtRwPropertiesList ( )
private

Not implemented.

DtRwPropertiesList::DtRwPropertiesList ( const DtString name,
DtReaderWriterRegistry parentRegistry = 0 
)
DtRwPropertiesList::DtRwPropertiesList ( const DtString name,
const DtPropertyInterface prototype,
DtReaderWriterRegistry parentRegistry = 0 
)
DtRwPropertiesList::DtRwPropertiesList ( const DtString name,
const DtRwPropertiesList orig,
DtReaderWriterRegistry parentRegistry = 0 
)
virtual DtRwPropertiesList::~DtRwPropertiesList ( )
virtual

Member Function Documentation

virtual bool DtRwPropertiesList::addItem ( DtPropertyInterface item)
virtual

Adds a new item to the end of the list of the same type as myPrototype. Returns this item so that it may be set by the caller.

static_cast<DtRwPropertiesStructure*>(propertiesList.add());
newItem->findAndSetPropertyValue<int>("Count", 4);

Reimplemented in DtRwPropertiesFixedArray.

virtual DtPropertyInterface* DtRwPropertiesList::addItem ( )
virtual

Adds a new item to the end of the list of the same type as myPrototype. Returns this item so that it may be set by the caller.

static_cast<DtRwPropertiesStructure*>(propertiesList.add());
newItem->findAndSetPropertyValue<int>("Count", 4);

Reimplemented in DtRwPropertiesFixedArray.

virtual void DtRwPropertiesList::erase ( DtPropertyInterface item)
virtual

Erases the item at the specified iterator position.

DtRwPropertiesList::iterator iter = propertiesList.begin();
for (; iter != propertiesList.end(); ++iter)
{
// Check for the one we want and break out if found
}
propertiesList.erase(iter);

Reimplemented in DtRwPropertiesFixedArray.

virtual void DtRwPropertiesList::erase ( iterator  pos)
virtual

Erases the item at the specified iterator position.

DtRwPropertiesList::iterator iter = propertiesList.begin();
for (; iter != propertiesList.end(); ++iter)
{
// Check for the one we want and break out if found
}
propertiesList.erase(iter);

Reimplemented in DtRwPropertiesFixedArray.

virtual const char* DtRwPropertiesList::readerWriterType ( ) const
virtual

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.

Reimplemented in DtRwPropertiesMap, and DtRwPropertiesFixedArray.

static const char* DtRwPropertiesList::theXmlType ( )
static

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

Referenced by DtRwPropertiesFixedArray::xmlType(), and DtRwPropertiesMap::xmlType().

virtual const char* DtRwPropertiesList::xmlType ( ) const
inlinevirtual

Reimplemented from DtReaderWriter.

Reimplemented in DtRwPropertiesMap, and DtRwPropertiesFixedArray.

References DtReaderWriter::theXmlType().

virtual char* DtRwPropertiesList::encode ( char ) const
virtual

Encodes the property into the supplied buffer. Does not align the property. Buffer must already be aligned correctly based on the hlaAlignment() value of this property.

Reimplemented from DtRwProperties.

Reimplemented in DtRwPropertiesFixedArray.

virtual const char* DtRwPropertiesList::decode ( const char )
virtual

Decodes the property from the specified buffer. Assumes buffer is the start of the property and preceding padding has been skipped.

Reimplemented from DtRwProperties.

Reimplemented in DtRwPropertiesFixedArray.

virtual void DtRwPropertiesList::getSize ( int size) const
virtual

Adds the network size of this item in bytes. This does not include any upfront padding for alignment.

Reimplemented from DtRwProperties.

Reimplemented in DtRwPropertiesFixedArray.

virtual int DtRwPropertiesList::hlaAlignment ( ) const
virtual

The required byte alignment of this property when encoding to HLA.

Reimplemented from DtRwProperties.

Reimplemented in DtRwPropertiesMap.

virtual bool DtRwPropertiesList::isValidProperty ( const DtPropertyInterface ) const
virtual

Returns true if this is a valid property for the properties list.

Reimplemented from DtRwProperties.

virtual int DtRwPropertiesList::count ( ) const
virtual

Returns the number of valid items in this list.

Reimplemented from DtRwProperties.

virtual void DtRwPropertiesList::getSelf ( DtlObjPtr  args,
const DtReaderWriter::SearchPaths searchPaths = DtReaderWriter::SearchPaths(),
const DtVariableBindingsList variableBindings = nullVariableReference() 
)
virtual

Reads in items, using the factory to read the correct types.

Reimplemented from DtRwProperties.

virtual void DtRwPropertiesList::writeSelf ( std::string &  fp,
int  indentLevel = 0,
bool  writeUnspecified = false,
const DtFilename &  path = DtFilename::nullFilename() 
)
virtual

Writes out registry data, but includes the type strings when writing.

Reimplemented from DtRwProperties.

virtual void DtRwPropertiesList::writeData ( std::string &  fp,
int  indentLevel = 0,
bool  writeUnspecified = false,
const DtFilename &  path = DtFilename::nullFilename() 
)
virtual

Reimplemented from DtRwProperties.

virtual void DtRwPropertiesList::setPrototype ( const DtPropertyInterface )
virtual

Sets the prototype for this list. Will be cloned and kept as part of this object.

virtual const DtPropertyInterface* DtRwPropertiesList::prototype ( ) const
virtual

Returns the prototype for this list.

virtual DtPropertyInterface* DtRwPropertiesList::clonePrototype ( DtReaderWriterRegistry parent = 0)
virtual

Returns a clone of the prototype that belongs to this list.

Reimplemented in DtRwPropertiesFixedArray.

DtRwPropertiesList& DtRwPropertiesList::operator= ( const DtRwPropertiesList )
virtual bool DtRwPropertiesList::isSimilarProperty ( const DtPropertyInterface rhs,
bool  strict = true 
) const
virtual

Returns true prototype is the same.

Reimplemented from DtPropertyInterface.

Reimplemented in DtRwPropertiesMap, and DtRwPropertiesFixedArray.

bool DtRwPropertiesList::operator== ( const DtRwPropertiesList ) const
virtual bool DtRwPropertiesList::matchPrototype ( const DtReaderWriter ) const
virtual
virtual void DtRwPropertiesList::writePrototype ( const DtReaderWriter ,
std::string &  fp,
int  indentLevel,
bool  writeHeader = true 
) const
protectedvirtual
virtual void DtRwPropertiesList::bindToRwAsVariable ( const DtReaderWriter rw)
protectedvirtual

Copies values from the specified DtReaderWriter. rw must point to the same subclassed type of DtReaderWriter as this instance is. Sets myVariableIsBound to true if variable binding is successful.

Reimplemented from DtReaderWriter.

virtual void DtRwPropertiesList::createListEntry ( DtPropertyInterface iFace,
DtlObjPtr  variableItem,
const DtReaderWriter::SearchPaths searchPaths,
const DtVariableBindingsList variableBindings 
)
protectedvirtual

Reimplemented in DtRwPropertiesMap.

virtual DtPropertyInterface* DtRwPropertiesList::createPrototype ( DtlObjPtr  )
protectedvirtual
virtual DtlObjPtr DtRwPropertiesList::variablesStart ( DtlObjPtr  args) const
protectedvirtual
virtual const char* DtRwPropertiesList::decode ( DtPropertyInterface ,
const char  
)
protectedvirtual

Decodes the variable bindings from the specified buffer.

Reimplemented from DtRwProperties.

Reimplemented in DtRwPropertiesMap.

virtual DtlObjPtr DtRwPropertiesList::getData ( DtlObjPtr  args,
const DtReaderWriter::SearchPaths searchPaths,
const DtVariableBindingsList variableBindings 
)
protectedvirtual

Override to allow a variable to be assigned to a property of derived type.

Reimplemented from DtRwProperties.

virtual void DtRwPropertiesList::getData ( const DtEnvironmentSP  ,
const DtEnvValueSP  ,
const DtReaderWriter::SearchPaths searchPaths,
const DtVariableBindingsList bindings 
)
protectedvirtual

Gets data from the environment value.

Reimplemented from DtReaderWriter.

Reimplemented in DtRwPropertiesMap.

virtual void DtRwPropertiesList::putData ( DtEnvironmentSP  ,
DtEnvValueSP  value 
) const
protectedvirtual

Override to add attributes of actual data.

Reimplemented from DtReaderWriter.

Reimplemented in DtRwPropertiesMap.

virtual void DtRwPropertiesList::assignPrototypeToChildren ( )
protectedvirtual
virtual void DtRwPropertiesList::setPrototypeIntoTarget ( const DtPropertyInterface prototype,
DtReaderWriter target 
)
protectedvirtual
virtual void DtRwPropertiesList::postWriteItem ( std::string &  fp,
DtReaderWriter rw,
int  indentLevel 
)
protectedvirtual

Reimplemented in DtRwPropertiesMap.

virtual void DtRwPropertiesList::preWriteItem ( std::string &  fp,
DtReaderWriter rw,
int  indentLevel 
)
protectedvirtual

Reimplemented in DtRwPropertiesMap.

virtual bool DtRwPropertiesList::matchPrototype ( const DtReaderWriter prototype,
const DtReaderWriter match 
) const
protectedvirtual
virtual void DtRwPropertiesList::cloneAndAddProperty ( const DtReaderWriter rw)
protectedvirtual

Clones the given RW and tries to add it to this list.

Reimplemented from DtRwProperties.

Member Data Documentation

DtPropertyInterface* DtRwPropertiesList::myPrototype
protected
DtRwPropertyInt DtRwPropertiesList::myCount
mutableprotected

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

Document ID: Generated on Thu Jun 1 17:58:13 EDT 2023 from SVN revision 255404
Copyright © 2005-2021 MAK Technologies. All Rights Reserved (www.mak.com)