33 #ifndef _D_STRUCTURE_TYPE_
34 #define _D_STRUCTURE_TYPE_
36 #if (defined(__VISUALC__) && !defined(__EXECUTABLE__))
37 #define __EXECUTABLE__
64 r_Structure_Type(
char* newTypeName,
unsigned int newNumAttrs, r_Attribute* newAttrs,
int offset = 0 );
93 r_Attribute
operator[](
unsigned int number )
const throw( r_Error );
105 virtual void print_status( std::ostream& s = std::cout )
const;
108 virtual void print_value(
const char* storage, std::ostream& s = std::cout )
const;
virtual bool isStructType() const
check, if type is primitive or structured.
r_Attribute resolve_attribute(const char *name) const
return attribute specified by name.
virtual r_Type::r_Type_Id type_id() const
retrieve id of the type.
Definition: structuretype.hh:56
attribute_iterator defines_attribute_end() const
returns attribute iterator at end position (behind last attribute).
std::ostream & operator<<(std::ostream &str, const r_Structure_Type &type)
unsigned int count_elements() const
get number of attributes
virtual r_Type * clone() const
clone operation
virtual ~r_Structure_Type()
destructor.
r_Attribute operator[](unsigned int number) const
subscript operator to access attributes by index
virtual void print_status(std::ostream &s=std::cout) const
writes state of object to specified stream
virtual void convertToBigEndian(char *cells, r_Area noCells) const
converts array of cells from Unix byte order to NT byte order.
unsigned int numAttrs
Definition: structuretype.hh:111
r_Structure_Type()
default constructor.
r_Type_Id
Definition: type.hh:61
r_Attribute * myAttributes
Definition: structuretype.hh:112
attribute_iterator defines_attribute_begin() const
returns attribute iterator at begin position.
r_IterType< r_Attribute > attribute_iterator
typedef for iterator iterating through all attributes;
Definition: structuretype.hh:60
const r_Structure_Type & operator=(const r_Structure_Type &oldObj)
assignment operator.
virtual void print_value(const char *storage, std::ostream &s=std::cout) const
prints values of a structured type
virtual bool compatibleWith(const r_Structure_Type *myType) const
check, if this type is compatible with myType (e.g. check the structure ignoring then names of atribu...
virtual void convertToLittleEndian(char *cells, r_Area noCells) const
converts array of cells from NT byte order to Unix byte order.