Main Page | Namespace List | Class Hierarchy | Alphabetical List | Class List | File List | Namespace Members | Class Members | File Members | Related Pages

PropertyContainer Class Reference

#include <textfile_evaluation.h>

Inheritance diagram for PropertyContainer:

Inheritance graph
[legend]
List of all members.

Public Types

typedef PointerList< Property * > Properties

Public Member Functions

virtual void openBracket (const ASCString &name)
virtual void closeBracket ()
ASCString getNameStack ()
void addString (const ASCString &name, ASCString &property)
void addString (const ASCString &name, ASCString &property, const ASCString &defaultValue)
void addStringArray (const ASCString &name, vector< ASCString > &property)
void addInteger (const ASCString &name, int &property)
void addInteger (const ASCString &name, int &property, int defaultValue)
void addDFloat (const ASCString &name, double &property)
void addDFloat (const ASCString &name, double &property, double defaultValue)
void addIntegerArray (const ASCString &name, vector< int > &property, bool required=true)
void addDFloatArray (const ASCString &name, vector< double > &property)
void addDFloatArray (const ASCString &name, vector< int > &property)
void addIntRangeArray (const ASCString &name, vector< IntRange > &property, bool required=true)
void addTagArray (const ASCString &name, BitSet &property, int tagNum, const char **tags, bool inverted=false)
void addTagInteger (const ASCString &name, int &property, int tagNum, const char **tags, bool inverted=false)
void addTagInteger (const ASCString &name, int &property, int tagNum, const char **tags, int defaultValue, bool inverted=false)
void addNamedInteger (const ASCString &name, int &property, int tagNum, const char **tags)
void addNamedInteger (const ASCString &name, int &property, int tagNum, const char **tags, int defaultValue)
void addBreakpoint ()
void addImage (const ASCString &name, Surface &property, const ASCString &fileName, bool applyFieldMask)
void addImageArray (const ASCString &name, vector< Surface > &property, const ASCString &fileName)
void addBool (const ASCString &name, bool &property)
void addBool (const ASCString &name, bool &property, bool defaultValue)
void storeContext (const ASCString &label)
bool restoreContext (const ASCString &label)
bool isReading ()
void warning (const ASCString &errmsg)
void error (const ASCString &errmsg)
bool find (const ASCString &name)
virtual ASCString getFileName ()=0
virtual ~PropertyContainer ()

Public Attributes

Properties properties

Protected Types

typedef list< ASCStringLevel
typedef map< ASCString, pair<
int, Level > > 
StoredContext

Protected Member Functions

 PropertyContainer (const ASCString &baseName, TextPropertyGroup *tpg, bool reading_)
virtual ASCString getLocation ()=0

Protected Attributes

int levelDepth
Level level
StoredContext storedContext
TextPropertyGrouptextPropertyGroup

Friends

class Property

Classes

class  Property

Member Typedef Documentation

typedef list<ASCString> PropertyContainer::Level [protected]
 

Definition at line 42 of file textfile_evaluation.h.

typedef PointerList<Property*> PropertyContainer::Properties
 

Definition at line 77 of file textfile_evaluation.h.

typedef map< ASCString, pair<int, Level> > PropertyContainer::StoredContext [protected]
 

Definition at line 45 of file textfile_evaluation.h.


Constructor & Destructor Documentation

virtual PropertyContainer::~PropertyContainer  )  [inline, virtual]
 

Definition at line 119 of file textfile_evaluation.h.

PropertyContainer::PropertyContainer const ASCString baseName,
TextPropertyGroup tpg,
bool  reading_
[inline, protected]
 

Definition at line 121 of file textfile_evaluation.h.


Member Function Documentation

void PropertyContainer::addBool const ASCString name,
bool &  property,
bool  defaultValue
 

Definition at line 401 of file textfile_evaluation.cpp.

void PropertyContainer::addBool const ASCString name,
bool &  property
 

Definition at line 395 of file textfile_evaluation.cpp.

Referenced by addBreakpoint(), TextPropertyGroup::buildInheritance(), ASCGUI_Window::parsePanelASCTXT(), ASCGUI_Window::WidgetParameters::runTextIO(), Vehicletype::HeightChangeMethod::runTextIO(), Vehicletype::runTextIO(), Technology::runTextIO(), TechDependency::runTextIO(), ItemFiltrationSystem::ItemFilter::runTextIO(), CGameOptions::runTextIO(), ContainerBaseType::TransportationIO::runTextIO(), and BuildingType::runTextIO().

void PropertyContainer::addBreakpoint  ) 
 

Definition at line 490 of file textfile_evaluation.cpp.

References addBool(), and isReading().

Referenced by ContainerBaseType::runTextIO(), and BuildingType::runTextIO().

void PropertyContainer::addDFloat const ASCString name,
double &  property,
double  defaultValue
 

Definition at line 387 of file textfile_evaluation.cpp.

void PropertyContainer::addDFloat const ASCString name,
double &  property
 

Definition at line 381 of file textfile_evaluation.cpp.

Referenced by ASCGUI_Window::parsePanelASCTXT(), and Vehicletype::runTextIO().

void PropertyContainer::addDFloatArray const ASCString name,
vector< int > &  property
 

Definition at line 439 of file textfile_evaluation.cpp.

void PropertyContainer::addDFloatArray const ASCString name,
vector< double > &  property
 

Definition at line 433 of file textfile_evaluation.cpp.

Referenced by ResourceMatrix::runTextIO(), and ObjectType::FieldModification::runTextIO().

void PropertyContainer::addImage const ASCString name,
Surface property,
const ASCString fileName,
bool  applyFieldMask
 

Definition at line 532 of file textfile_evaluation.cpp.

Referenced by Vehicletype::runTextIO(), and BuildingType::runTextIO().

void PropertyContainer::addImageArray const ASCString name,
vector< Surface > &  property,
const ASCString fileName
 

Definition at line 525 of file textfile_evaluation.cpp.

void PropertyContainer::addInteger const ASCString name,
int &  property,
int  defaultValue
 

Definition at line 375 of file textfile_evaluation.cpp.

void PropertyContainer::addInteger const ASCString name,
int &  property
 

Definition at line 369 of file textfile_evaluation.cpp.

Referenced by TextPropertyGroup::buildInheritance(), TextPropertyGroup::evalID(), ASCGUI_Window::parsePanelASCTXT(), ASCGUI_Window::parseRect(), ASCGUI_Window::WidgetParameters::runTextIO(), Vehicletype::HeightChangeMethod::runTextIO(), SingleWeapon::runTextIO(), Vehicletype::runTextIO(), Technology::runTextIO(), CGameOptions::runTextIO(), ContainerBaseType::runTextIO(), ContainerBaseType::TransportationIO::runTextIO(), BuildingType::runTextIO(), ASCGUI_Window::setup(), and CargoDialog::userHandler().

void PropertyContainer::addIntegerArray const ASCString name,
vector< int > &  property,
bool  required = true
 

Definition at line 427 of file textfile_evaluation.cpp.

Referenced by TextPropertyGroup::buildInheritance(), Vehicletype::runTextIO(), Technology::runTextIO(), BuildingType::runTextIO(), and transformMap().

void PropertyContainer::addIntRangeArray const ASCString name,
vector< IntRange > &  property,
bool  required = true
 

Definition at line 453 of file textfile_evaluation.cpp.

Referenced by TechDependency::runTextIO(), and ItemFiltrationSystem::ItemFilter::runTextIO().

void PropertyContainer::addNamedInteger const ASCString name,
int &  property,
int  tagNum,
const char **  tags,
int  defaultValue
 

Definition at line 484 of file textfile_evaluation.cpp.

void PropertyContainer::addNamedInteger const ASCString name,
int &  property,
int  tagNum,
const char **  tags
 

Definition at line 478 of file textfile_evaluation.cpp.

Referenced by ASCGUI_Window::parsePanelASCTXT(), ASCGUI_Window::WidgetParameters::runTextIO(), Vehicletype::runTextIO(), and CGameOptions::runTextIO().

void PropertyContainer::addString const ASCString name,
ASCString property,
const ASCString defaultValue
 

Definition at line 413 of file textfile_evaluation.cpp.

void PropertyContainer::addString const ASCString name,
ASCString property
 

Definition at line 407 of file textfile_evaluation.cpp.

Referenced by Panel::getDefaultWidgetParams(), ASCGUI_Window::parsePanelASCTXT(), ASCGUI_Window::WidgetParameters::runTextIO(), SingleWeapon::runTextIO(), Vehicletype::runTextIO(), Technology::runTextIO(), Campaign::runTextIO(), MusicPlayList::runTextIO(), ItemFiltrationSystem::ItemFilter::runTextIO(), CGameOptions::runTextIO(), BuildingType::runTextIO(), and ASCGUI_Window::setup().

void PropertyContainer::addStringArray const ASCString name,
vector< ASCString > &  property
 

Definition at line 420 of file textfile_evaluation.cpp.

Referenced by ASCGUI_Window::parsePanelASCTXT(), MusicPlayList::runTextIO(), and CGameOptions::runTextIO().

void PropertyContainer::addTagArray const ASCString name,
BitSet property,
int  tagNum,
const char **  tags,
bool  inverted = false
 

Definition at line 460 of file textfile_evaluation.cpp.

Referenced by Vehicletype::runTextIO(), TerrainAccess::runTextIO(), ObjectType::FieldModification::runTextIO(), ContainerBaseType::TransportationIO::runTextIO(), and BuildingType::runTextIO().

void PropertyContainer::addTagInteger const ASCString name,
int &  property,
int  tagNum,
const char **  tags,
int  defaultValue,
bool  inverted = false
 

Definition at line 472 of file textfile_evaluation.cpp.

void PropertyContainer::addTagInteger const ASCString name,
int &  property,
int  tagNum,
const char **  tags,
bool  inverted = false
 

Definition at line 466 of file textfile_evaluation.cpp.

Referenced by Vehicletype::HeightChangeMethod::runTextIO(), SingleWeapon::runTextIO(), Vehicletype::runTextIO(), ContainerBaseType::TransportationIO::runTextIO(), and BuildingType::runTextIO().

void PropertyContainer::closeBracket  )  [virtual]
 

Reimplemented in PropertyWritingContainer.

Definition at line 327 of file textfile_evaluation.cpp.

References level, and levelDepth.

Referenced by PropertyWritingContainer::closeBracket(), ASCGUI_Window::parsePanelASCTXT(), SingleWeapon::runTextIO(), Vehicletype::runTextIO(), ObjectType::FieldModification::runTextIO(), CGameOptions::runTextIO(), BuildingType::runTextIO(), and WeaponInfoPanel::WeaponInfoPanel().

void PropertyContainer::error const ASCString errmsg  ) 
 

Definition at line 550 of file textfile_evaluation.cpp.

References displayLogMessage(), and getLocation().

Referenced by PropertyContainer::Property::findEntry(), ValArrayProperty< T >::operation_add(), ASCImageArrayProperty::operation_eq(), ASCImageProperty::operation_eq(), NamedIntProperty::operation_eq(), TagIntProperty::operation_eq(), TagArrayProperty::operation_eq(), BoolProperty::operation_eq(), ValArrayProperty< T >::operation_mult(), ValArrayProperty< T >::operation_sub(), PropertyTemplate< T >::parse(), ResourceMatrix::runTextIO(), BuildingType::runTextIO(), and PropertyWritingContainer::~PropertyWritingContainer().

bool PropertyContainer::find const ASCString name  ) 
 

Definition at line 556 of file textfile_evaluation.cpp.

References TextPropertyGroup::find(), level, textPropertyGroup, and ASCString::toLower().

Referenced by ASCGUI_Window::parsePanelASCTXT(), ASCGUI_Window::WidgetParameters::runTextIO(), SingleWeapon::runTextIO(), Vehicletype::runTextIO(), ResourceMatrix::runTextIO(), Technology::runTextIO(), TechDependency::runTextIO(), ItemFiltrationSystem::ItemFilter::runTextIO(), CGameOptions::runTextIO(), ContainerBaseType::TransportationIO::runTextIO(), BuildingType::runTextIO(), ASCGUI_Window::setup(), and transformMap().

virtual ASCString PropertyContainer::getFileName  )  [pure virtual]
 

Implemented in PropertyReadingContainer, and PropertyWritingContainer.

Referenced by Vehicletype::runTextIO(), ContainerBaseType::TransportationIO::runTextIO(), and BuildingType::runTextIO().

virtual ASCString PropertyContainer::getLocation  )  [protected, pure virtual]
 

Implemented in PropertyReadingContainer, and PropertyWritingContainer.

Referenced by error().

ASCString PropertyContainer::getNameStack  ) 
 

Definition at line 310 of file textfile_evaluation.cpp.

References level.

Referenced by ASCGUI_Window::parsePanelASCTXT().

bool PropertyContainer::isReading  )  [inline]
 

Definition at line 114 of file textfile_evaluation.h.

Referenced by addBreakpoint(), PropertyTemplate< T >::evaluate(), SingleWeapon::runTextIO(), Vehicletype::runTextIO(), ResourceMatrix::runTextIO(), Technology::runTextIO(), TechDependency::runTextIO(), CGameOptions::runTextIO(), ContainerBaseType::TransportationIO::runTextIO(), and BuildingType::runTextIO().

void PropertyContainer::openBracket const ASCString name  )  [virtual]
 

Reimplemented in PropertyWritingContainer.

Definition at line 321 of file textfile_evaluation.cpp.

References level, and levelDepth.

Referenced by PropertyWritingContainer::openBracket(), ASCGUI_Window::parsePanelASCTXT(), PropertyReadingContainer::PropertyReadingContainer(), SingleWeapon::runTextIO(), Vehicletype::runTextIO(), ObjectType::FieldModification::runTextIO(), CGameOptions::runTextIO(), ContainerBaseType::runTextIO(), BuildingType::runTextIO(), UnitInfoDialog::userHandler(), CargoDialog::userHandler(), and WeaponInfoPanel::WeaponInfoPanel().

bool PropertyContainer::restoreContext const ASCString label  ) 
 

Definition at line 511 of file textfile_evaluation.cpp.

References level, levelDepth, and storedContext.

void PropertyContainer::storeContext const ASCString label  ) 
 

Definition at line 506 of file textfile_evaluation.cpp.

References level, levelDepth, and storedContext.

void PropertyContainer::warning const ASCString errmsg  ) 
 

Definition at line 541 of file textfile_evaluation.cpp.

References fatalError(), TextPropertyGroup::fileName, and textPropertyGroup.


Friends And Related Function Documentation

friend class Property [friend]
 

Definition at line 73 of file textfile_evaluation.h.


Member Data Documentation

Level PropertyContainer::level [protected]
 

Definition at line 43 of file textfile_evaluation.h.

Referenced by PropertyWritingContainer::closeBracket(), closeBracket(), find(), getNameStack(), openBracket(), restoreContext(), and storeContext().

int PropertyContainer::levelDepth [protected]
 

Definition at line 41 of file textfile_evaluation.h.

Referenced by PropertyWritingContainer::closeBracket(), closeBracket(), PropertyWritingContainer::openBracket(), openBracket(), restoreContext(), storeContext(), PropertyWritingContainer::writeProperty(), and PropertyWritingContainer::~PropertyWritingContainer().

Properties PropertyContainer::properties
 

Definition at line 78 of file textfile_evaluation.h.

StoredContext PropertyContainer::storedContext [protected]
 

Definition at line 46 of file textfile_evaluation.h.

Referenced by restoreContext(), and storeContext().

TextPropertyGroup* PropertyContainer::textPropertyGroup [protected]
 

Definition at line 48 of file textfile_evaluation.h.

Referenced by find(), PropertyContainer::Property::findEntry(), PropertyReadingContainer::getFileName(), PropertyReadingContainer::getLocation(), PropertyWritingContainer::PropertyWritingContainer(), warning(), and PropertyWritingContainer::~PropertyWritingContainer().


The documentation for this class was generated from the following files:
Generated on Tue Jun 24 02:19:57 2008 for Advanced Strategic Command by  doxygen 1.4.2