00001
00002
00003
00004
00005
00006
00007
00008
00009 #ifndef _DATA_ELEMENT_H
00010 #define _DATA_ELEMENT_H
00011
00012 class SrcFinfo;
00013 class FuncOrder;
00014
00021 class DataElement: public Element
00022 {
00023 public:
00035 DataElement( Id id, const Cinfo* c, const string& name,
00036 unsigned int numData = 1 );
00037
00042 DataElement( Id id, const Element* orig, unsigned int n,
00043 unsigned int startEntry );
00044
00048 ~DataElement();
00049
00054
00055
00057
00059
00061 unsigned int numLocalData() const;
00062
00064
00066 unsigned int numField( unsigned int rawIndex ) const;
00067
00072 unsigned int totNumLocalField() const;
00073
00075
00081 bool hasFields() const {
00082 return false;
00083 }
00084
00086
00088
00105 char* data( unsigned int rawIndex,
00106 unsigned int fieldIndex = 0 ) const;
00107
00114 void resize( unsigned int newNumData );
00115
00121 void resizeField(
00122 unsigned int rawIndex, unsigned int newNumField )
00123 {;}
00124
00126
00127
00129 void zombieSwap( const Cinfo* newCinfo );
00130
00131 private:
00132
00136 char* data_;
00137
00141 unsigned int numLocalData_;
00142
00148 unsigned int size_;
00149 };
00150
00151 #endif // _DATA_ELEMENT_H