Main Page   Class Hierarchy   Compound List   Compound Members  

Resource Class Reference

List of all members.

Public Methods

 Resource ()
 ~Resource ()
Resource operator= (const Resource &r)
 Resource (const Resource &r)
 Resource (const char *filename, const char *xpath, int iomode, int *status)
int openFile (const char *filename, const char *xpath, int iomode, int *status)
int closeFile (int *status)
int getDescription (char *&desc, int *status)
int getID (char *&ID, int *status)
int getName (char *&name, int *status)
int getType (resource_type &value, int *status)
int getNumOfInfos (int &numOfElements, int *status)
int getInfo (Info &info, int index, int *status)
int getNumOfCoosys (int &numOfElements, int *status)
int getCoosys (Coosys &coosys, int index, int *status)
int getNumOfParams (int &numOfElements, int *status)
int getParam (Param &param, int index, int *status)
int getNumOfLinks (int &numOfElements, int *status)
int getLink (Link &link, int index, int *status)
int getNumOfTables (int &numOfElements, int *status)
int getTable (VTable &table, int index, int *status)
int getNumOfResources (int &numOfElements, int *status)
int getResource (Resource &resource, int index, int *status)

Detailed Description

This class represents <RESOURCE> element in the VOTable.

A RESOURCE element contains description, list of 'Info' elements, list of 'Coosys' elements, list of 'Param' elements, list of 'Link' elements, list of 'Table' elements, and 'list' of Resource elements.


Constructor & Destructor Documentation

Resource.Resource  
 

Default constructor

Resource.~Resource  
 

Destructor

Resource.Resource const Resource &    r
 

Copy constructor.

Resource.Resource const char *    filename,
const char *    xpath,
int    iomode,
int *    status
 

Constructs a 'Resource' from <RESOURCE> element from the given VOTABLE file, the xpath denotes the position of the resource element to be opened.

Example - To read the first <RESOURCE> use "/RESOURCE[1]" in the xpath. To read a <RESOURCE> with ID as 'ycat' use "/RESOURCE[@ID='ycat']" in the xpath.

Make sure that the xpath points to a single <RESOURCE> element, else VOERROR will be returned.

Currently the parameter 'iomode' is ignored since all files are opened in 'readonly' mode.


Member Function Documentation

int Resource.closeFile int *    status
 

Closes the 'Resource' element.

int Resource.getCoosys Coosys   coosys,
int    index,
int *    status
 

Get the 'Coosys' element, given the index. Index starts from 0.

int Resource.getDescription char *&    desc,
int *    status
 

Get the 'description' of resource.

int Resource.getID char *&    ID,
int *    status
 

Get the 'ID'.

int Resource.getInfo Info   info,
int    index,
int *    status
 

Get the 'Info' element, given the index. Index starts from 0.

int Resource.getLink Link   link,
int    index,
int *    status
 

Get the 'Link' element, given the index. Index starts from 0.

int Resource.getName char *&    name,
int *    status
 

Get the 'name'.

int Resource.getNumOfCoosys int &    numOfElements,
int *    status
 

Get the number of 'Coosys' elements.

int Resource.getNumOfInfos int &    numOfElements,
int *    status
 

Get the number of 'Info' elements.

int Resource.getNumOfLinks int &    numOfElements,
int *    status
 

Get the number of 'Link' elements.

int Resource.getNumOfParams int &    numOfElements,
int *    status
 

Get the number of 'Param' elements.

int Resource.getNumOfResources int &    numOfElements,
int *    status
 

Get the number of 'Resource' elements.

int Resource.getNumOfTables int &    numOfElements,
int *    status
 

Get the number of 'VTable' elements.

int Resource.getParam Param   param,
int    index,
int *    status
 

Get the 'Param' element, given the index. Index starts from 0.

int Resource.getResource Resource &    resource,
int    index,
int *    status
 

Get the 'Resource' element, given the index. Index starts from 0.

int Resource.getTable VTable   table,
int    index,
int *    status
 

Get the 'VTable' element, given the index. Index starts from 0.

int Resource.getType resource_type &    value,
int *    status
 

Get the 'type'.

int Resource.openFile const char *    filename,
const char *    xpath,
int    iomode,
int *    status
 

Opens a Resource element from the given VOTABLE file, the xpath denotes the position of the resource element to be opened.

Example - To read the first <RESOURCE> use "/RESOURCE[1]" in the xpath. To read a <RESOURCE> with ID as 'ycat' use "/RESOURCE[@ID='ycat']" in the xpath. Note that xpath is case sensitive.

Make sure that the xpath points to a single <RESOURCE> element, else VOERROR will be returned.

Currently the parameter 'iomode' is ignored since all files are opened in 'readonly' mode.

Resource Resource.operator= const Resource &    r
 

Assignment operator overloaded.


Generated on Mon Jul 15 14:07:15 2002 for VOTable Parser 1.2 by doxygen1.2.16