34 #ifndef DataDescriptionTable_CLASS
35 #define DataDescriptionTable_CLASS
75 class DataDescriptionRow;
144 static const std::vector<std::string>&
getKeyName();
161 unsigned int size()
const;
179 static std::string
name() ;
219 std::string
toXML() ;
228 asdmIDL::DataDescriptionTableIDL *
toIDL() ;
237 void toIDL(asdmIDL::DataDescriptionTableIDL& x)
const;
248 void fromIDL(asdmIDL::DataDescriptionTableIDL x) ;
318 std::vector<DataDescriptionRow *>
get() ;
326 const std::vector<DataDescriptionRow *>&
get()
const ;
430 std::vector<DataDescriptionRow *>
row;
488 void toFile(std::string directory);
static const ByteOrder * Machine_Endianity
void append(DataDescriptionRow *x)
Brutally append an DataDescriptionRow x to the collection of rows already stored in this table...
void fromXML(std::string &xmlDoc)
Populate this table from the content of a XML document that is required to be conform to the XML sche...
DataDescriptionRow * lookup(Tag polOrHoloId, Tag spectralWindowId)
Look up the table for a row whose all attributes except the autoincrementable one are equal to the co...
void addWithoutCheckingUnique(DataDescriptionRow *x)
Brutally append an DataDescriptionRow x to the collection of rows already stored in this table...
void toFile(std::string directory)
Stores a representation (binary or XML) of this table into a file.
A class to represent byte order information.
void autoIncrement(std::string key, DataDescriptionRow *x)
unsigned int size() const
Return the number of rows in the table.
void setFromXMLFile(const std::string &directory)
static const std::vector< std::string > & getAttributesNames()
Return the names of the attributes of this table.
virtual ~DataDescriptionTable()
std::string toMIME(const asdm::ByteOrder *byteOrder=asdm::ByteOrder::Machine_Endianity)
Serialize this into a stream of bytes and encapsulates that stream into a MIME message.
The ASDM class is the container for all tables.
void checkPresenceInMemory()
void setFromMIMEFile(const std::string &directory)
Private methods involved during the build of this table out of the content of file(s) containing an e...
The DataDescriptionTable class is an Alma table.
std::string getName() const
Return the name of this table.
void fromIDL(asdmIDL::DataDescriptionTableIDL x)
Populate this table from the content of a DataDescriptionTableIDL Corba structure.
std::string MIMEXMLPart(const asdm::ByteOrder *byteOrder=asdm::ByteOrder::Machine_Endianity)
Private methods involved during the export of this table into disk file(s).
asdmIDL::DataDescriptionTableIDL * toIDL()
Conversion Methods.
std::map< std::string, int > noAutoIncIds
A map for the autoincrementation algorithm.
std::string getVersion() const
Return the version information about this table.
DataDescriptionRow * checkAndAdd(DataDescriptionRow *x, bool skipCheckUniqueness=false)
If this table has an autoincrementable attribute then check if *x verifies the rule of uniqueness and...
static const std::vector< std::string > & defaultAttributesNamesInBin()
Return the default sorted list of attributes names in the binary representation of the table...
void setFromMIME(const std::string &mimeMsg)
Extracts the binary part of a MIME message and deserialize its content to fill this with the result o...
static std::string name()
Return the name of this table.
std::map< std::string, BinaryAttributeReaderFunctor * > unknownAttributes2Functors
void setEntity(Entity e)
Set this table's Entity.
BinaryAttributeReaderFunctor * getUnknownAttributeBinaryReader(const std::string &attributeName) const
std::string toXML()
Produces an XML representation conform to the schema defined for DataDescription (DataDescriptionTabl...
void setFromFile(const std::string &directory)
Reads and parses a file containing a representation of a DataDescriptionTable as those produced by th...
The Tag class is an implementation of a unique index identifying a row of an ASDM table...
The DataDescriptionRow class is a row of a DataDescriptionTable.
A pure virtual class whose derived classes are expected to be functors whose behaviours will be to re...
The Representable interface is implemented by all tables and by the container.
const Double e
e and functions thereof:
DataDescriptionRow * getRowByKey(Tag dataDescriptionId)
Returns a DataDescriptionRow* given a key.
std::vector< DataDescriptionRow * > privateRows
A data structure to store the pointers on the table's rows.
DataDescriptionTable(ASDM &container)
Create a DataDescriptionTable.
DataDescriptionRow * add(DataDescriptionRow *x)
====> Append a row to its table.
bool loadInProgress
Load the table in memory if necessary.
void setUnknownAttributeBinaryReader(const std::string &attributeName, BinaryAttributeReaderFunctor *barFctr)
ASDM & getContainer() const
Return the container to which this table belongs.
static const std::vector< std::string > & getKeyName()
Return the list of field names that make up key key as an array of strings.
DataDescriptionRow * newRow()
====> Row creation.
Entity getEntity() const
Return this table's Entity.
std::vector< DataDescriptionRow * > row
The Entity class is an identification of a persistant entity in the ALMA archive. ...