NIREP

ResourceDescriptionList Class Reference

Collaboration diagram for ResourceDescriptionList:

List of all members.

Public Types

typedef std::map< std::string,
BasicDescription * > 
BasicList
typedef std::map< std::string,
ResourceDescriptionList * > 
RDLList
typedef std::map< std::string,
ResourceDescription * > 
ResourceList

Public Member Functions

void AddAlgorithmDescrip (std::string key, BasicDescription *value)
void AddCSDescrip (std::string key, BasicDescription *value)
bool AddDataDescrip (std::string key, ResourceDescription *value)
void AddLabelDescrip (std::string key, BasicDescription *value)
void AddNameSpaceDescrip (std::string key, BasicDescription *value)
void AddRDL (const std::string &filename, ResourceDescriptionList *rdl)
 Add RDL to root resource description list.
bool AddTransformDescrip (std::string key, ResourceDescription *value)
void Clear ()
 Removes all characters from strings and all elements from maps.
void ClearAlgorithmDescrips ()
void ClearCSDescrips ()
void ClearDataDescrips ()
void ClearLabelDescrips ()
void ClearNameSpaceDescrips ()
void ClearRDLs ()
void ClearTransformDescrips ()
std::vector< std::string > * CreateAlgorithmList ()
 Returns a pointer to a vector of strings that contains all the algorithms in the RDL. This method allocates memory that the calling method is responsible for deleting.
std::vector< std::string > * CreateCSList ()
 Returns a pointer to a vector of strings that contains all the coordinate systems in the RDL. This method allocates memory that the calling method is responsible for deleting.
std::vector< std::string > * CreateLabelList ()
 Returns a pointer to a vector of strings that contains all the algorithms in the RDL. This method allocates memory that the calling method is responsible for deleting.
std::vector< std::string > * CreateNameSpaceList ()
 Returns a pointer to a vector of strings that contains all the namespaces in the RDL. This method allocates memory that the calling method is responsible for deleting.
std::vector< std::string > * CreateRDLFilenameList ()
 Return a pointer to a vector of strings that contains a list of all the RDL filenames. This method allocates memory that the calling method is responsible for deleting.
BasicListGetAlgorithmDescrip ()
 Accessor functions for algorithm description.
BasicDescriptionGetAlgorithmDescrip (std::string key)
BasicListGetCSDescrip ()
 Accessor functions for coordinate system description.
BasicDescriptionGetCSDescrip (std::string key)
ResourceDescriptionGetDataDescrip (std::string key)
 returns description of data associated with key or NULL if key is missing
std::string & GetFilename ()
 Accessor functions for resource description list filename.
BasicListGetLabelDescrip ()
 Accessor functions for label description.
BasicDescriptionGetLabelDescrip (std::string key)
std::string & GetNameSpace ()
 Accessor functions for namespace.
BasicListGetNameSpaceDescrip ()
 Accessor functions for namespace description.
BasicDescriptionGetNameSpaceDescrip (std::string key)
 returns description of name space associated with key or NULL if key is missing
ResourceDescriptionListGetParentRDL ()
 Returns parent resource description list pointer.
ResourceDescriptionListGetRDL (const std::string &filename)
 Returns resource description list associated with key or NULL if key is missing.
ResourceDescriptionGetTransformDescrip (std::string key)
 returns description of transform associated with key or NULL if key is missing
bool Load ()
 Reads DOM from XML file specified by filename and sets the member variables of this object.
bool Load (const std::string &rdl_filename)
bool LoadFromDisplayDescription (const std::string &displayDescriptionFilename)
 Read RDL filenames from the displayDescriptionFilename and then call load.
 ResourceDescriptionList (const std::string &rdl_filename, ResourceDescriptionList *parent=NULL)
 This constructor takes a filename of a data resource file, parses the xml, and stores the data from the data resource file in this object's data list DataDescription objects.
 ResourceDescriptionList (ResourceDescriptionList *parent=NULL)
 Default Constructor creates an empty resource description list.
bool Save (const std::string &filename)
 Saves resource data list to the filename stored in this object.
bool Save (FILE *)
 Saves resource data list to the filename stored in this object.
bool Save ()
 Constructs a DOM for the resource description list and saves to an XML file specified by filename. Note that Save does not recursively children resource description lists.
void SetAlgorithmDescrip (const BasicList &algorithm_descrip)
void SetCSDescrip (const BasicList &cs_descrip)
void SetFilename (const std::string &filename)
void SetLabelDescrip (const BasicList &label_descrip)
void SetNameSpace (const std::string &_namespace)
void SetNameSpaceDescrip (const BasicList &namespace_descrip)
void SetParentRDL (ResourceDescriptionList *parent)
 ~ResourceDescriptionList ()
 Destructor clears all member objects.

Member Typedef Documentation

typedef std::map<std::string, BasicDescription *> ResourceDescriptionList::BasicList

Constructor & Destructor Documentation

ResourceDescriptionList::ResourceDescriptionList ( ResourceDescriptionList parent = NULL) [inline]

Default Constructor creates an empty resource description list.

ResourceDescriptionList::ResourceDescriptionList ( const std::string &  rdl_filename,
ResourceDescriptionList parent = NULL 
) [inline]

This constructor takes a filename of a data resource file, parses the xml, and stores the data from the data resource file in this object's data list DataDescription objects.

Parameters:
filename
ResourceDescriptionList::~ResourceDescriptionList ( ) [inline]

Destructor clears all member objects.


Member Function Documentation

void ResourceDescriptionList::AddAlgorithmDescrip ( std::string  key,
BasicDescription value 
) [inline]
void ResourceDescriptionList::AddCSDescrip ( std::string  key,
BasicDescription value 
) [inline]
bool ResourceDescriptionList::AddDataDescrip ( std::string  key,
ResourceDescription value 
) [inline]
void ResourceDescriptionList::AddLabelDescrip ( std::string  key,
BasicDescription value 
) [inline]
void ResourceDescriptionList::AddNameSpaceDescrip ( std::string  key,
BasicDescription value 
) [inline]
ResourceDescriptionList::AddRDL ( const std::string &  filename,
ResourceDescriptionList rdl 
) [inline]

Add RDL to root resource description list.

bool ResourceDescriptionList::AddTransformDescrip ( std::string  key,
ResourceDescription value 
) [inline]
void ResourceDescriptionList::Clear ( void  )

Removes all characters from strings and all elements from maps.

void ResourceDescriptionList::ClearAlgorithmDescrips ( ) [inline]
void ResourceDescriptionList::ClearCSDescrips ( ) [inline]
void ResourceDescriptionList::ClearDataDescrips ( ) [inline]
void ResourceDescriptionList::ClearLabelDescrips ( ) [inline]
void ResourceDescriptionList::ClearNameSpaceDescrips ( ) [inline]
void ResourceDescriptionList::ClearRDLs ( ) [inline]
void ResourceDescriptionList::ClearTransformDescrips ( ) [inline]
std::vector<std::string>* ResourceDescriptionList::CreateAlgorithmList ( ) [inline]

Returns a pointer to a vector of strings that contains all the algorithms in the RDL. This method allocates memory that the calling method is responsible for deleting.

std::vector<std::string>* ResourceDescriptionList::CreateCSList ( ) [inline]

Returns a pointer to a vector of strings that contains all the coordinate systems in the RDL. This method allocates memory that the calling method is responsible for deleting.

std::vector<std::string>* ResourceDescriptionList::CreateLabelList ( ) [inline]

Returns a pointer to a vector of strings that contains all the algorithms in the RDL. This method allocates memory that the calling method is responsible for deleting.

std::vector<std::string>* ResourceDescriptionList::CreateNameSpaceList ( ) [inline]

Returns a pointer to a vector of strings that contains all the namespaces in the RDL. This method allocates memory that the calling method is responsible for deleting.

std::vector<std::string>* ResourceDescriptionList::CreateRDLFilenameList ( ) [inline]

Return a pointer to a vector of strings that contains a list of all the RDL filenames. This method allocates memory that the calling method is responsible for deleting.

ResourceDescriptionList::GetAlgorithmDescrip ( ) [inline]

Accessor functions for algorithm description.

returns description of algorithm associated with key or NULL if key is missing

Parameters:
key= algorithm identifier
BasicDescription* ResourceDescriptionList::GetAlgorithmDescrip ( std::string  key) [inline]
BasicDescription* ResourceDescriptionList::GetCSDescrip ( std::string  key) [inline]
ResourceDescriptionList::GetCSDescrip ( ) [inline]

Accessor functions for coordinate system description.

returns description of coordinate system associated with key or NULL if key is missing

Parameters:
key= namespace and coordinate system identifier
ResourceDescriptionList::GetDataDescrip ( std::string  key) [inline]

returns description of data associated with key or NULL if key is missing

Parameters:
key= dmid (data manager id)
std::string& ResourceDescriptionList::GetFilename ( ) [inline]

Accessor functions for resource description list filename.

BasicDescription* ResourceDescriptionList::GetLabelDescrip ( std::string  key) [inline]
ResourceDescriptionList::GetLabelDescrip ( ) [inline]

Accessor functions for label description.

returns description of label associated with key or NULL if key is missing

Parameters:
key= label identifier
std::string& ResourceDescriptionList::GetNameSpace ( ) [inline]

Accessor functions for namespace.

BasicList& ResourceDescriptionList::GetNameSpaceDescrip ( ) [inline]

Accessor functions for namespace description.

BasicDescription* ResourceDescriptionList::GetNameSpaceDescrip ( std::string  key) [inline]

returns description of name space associated with key or NULL if key is missing

Parameters:
key= name space identifier
ResourceDescriptionList::GetParentRDL ( ) [inline]

Returns parent resource description list pointer.

ResourceDescriptionList::GetRDL ( const std::string &  filename) [inline]

Returns resource description list associated with key or NULL if key is missing.

Parameters:
filename= resource description list filename
ResourceDescriptionList::GetTransformDescrip ( std::string  key) [inline]

returns description of transform associated with key or NULL if key is missing

Parameters:
key= dmid (data manager id)
ResourceDescriptionList::Load ( ) [inline]

Reads DOM from XML file specified by filename and sets the member variables of this object.

Loads the resource description list specified by filename.

Loads the resource description list from filename stored in this object.

filename

bool ResourceDescriptionList::Load ( const std::string &  rdl_filename)
ResourceDescriptionList::LoadFromDisplayDescription ( const std::string &  displayDescriptionFilename)

Read RDL filenames from the displayDescriptionFilename and then call load.

bool ResourceDescriptionList::Save ( FILE *  file)

Saves resource data list to the filename stored in this object.

ResourceDescriptionList::Save ( ) [inline]

Constructs a DOM for the resource description list and saves to an XML file specified by filename. Note that Save does not recursively children resource description lists.

Saves resource data list to the filename stored in this object.

bool ResourceDescriptionList::Save ( const std::string &  filename)

Saves resource data list to the filename stored in this object.

void ResourceDescriptionList::SetAlgorithmDescrip ( const BasicList algorithm_descrip) [inline]
void ResourceDescriptionList::SetCSDescrip ( const BasicList cs_descrip) [inline]
void ResourceDescriptionList::SetFilename ( const std::string &  filename) [inline]
void ResourceDescriptionList::SetLabelDescrip ( const BasicList label_descrip) [inline]
void ResourceDescriptionList::SetNameSpace ( const std::string &  _namespace) [inline]
void ResourceDescriptionList::SetNameSpaceDescrip ( const BasicList namespace_descrip) [inline]
void ResourceDescriptionList::SetParentRDL ( ResourceDescriptionList parent) [inline]
 All Classes Functions Variables Typedefs Enumerations Enumerator