/[escript]/trunk/escript/src/DataAbstract.cpp
ViewVC logotype

Diff of /trunk/escript/src/DataAbstract.cpp

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 1796 by jfenwick, Wed Sep 17 01:45:46 2008 UTC revision 1803 by jfenwick, Wed Sep 24 06:20:29 2008 UTC
# Line 20  using namespace std; Line 20  using namespace std;
20    
21  namespace escript {  namespace escript {
22    
23  // DataAbstract::DataAbstract(const FunctionSpace& what):  DataAbstract::DataAbstract(const FunctionSpace& what, const ShapeType& shape, bool isDataEmpty):
 //     m_noDataPointsPerSample(what.getNumDPPSample()),  
 //     m_noSamples(what.getNumSamples()),  
 //     m_functionSpace(what),  
 //     m_rank(0)  
 // {  
 //  setShape(DataTypes::ShapeType());  
 // }  
   
   
 DataAbstract::DataAbstract(const FunctionSpace& what, const ShapeType& shape):  
24      m_noDataPointsPerSample(what.getNumDPPSample()),      m_noDataPointsPerSample(what.getNumDPPSample()),
25      m_noSamples(what.getNumSamples()),      m_noSamples(what.getNumSamples()),
26      m_functionSpace(what),      m_functionSpace(what),
27      m_shape(shape),      m_shape(shape),
28      m_rank(DataTypes::getRank(shape)),      m_rank(DataTypes::getRank(shape)),
29      m_novalues(DataTypes::noValues(shape))      m_novalues(DataTypes::noValues(shape))
   
30  {  {
31        m_isempty=isDataEmpty;
32  }  }
33    
34  DataAbstract::~DataAbstract()  DataAbstract::~DataAbstract()
35  {  {
36  }  }
37    
 // void  
 // DataAbstract::setPointDataView(const DataArrayView& input)  
 // {  
 //     m_pointDataView.reset(new DataArrayView(input.getData(),input.getShape(),input.getOffset()));  
 //  
 //     // until we get rid of m_pointDataView, we need to keep m_shape in sync  
 //     setShape(input.getShape());  
 // }  
   
 // perhaps this should be a constructor parameter  
 // void  
 // DataAbstract::setShape(const DataTypes::ShapeType& s)  
 // {  
 //    m_shape=s;  
 //    m_rank=DataTypes::getRank(s);  
 //    m_novalues=DataTypes::noValues(s);  
 // }  
   
   
 // void  
 // DataAbstract::resetPointDataView()  
 // {  
 //     m_pointDataView.reset(new DataArrayView());  
 //     m_shape.clear();  
 //     m_rank=0;  
 //     m_novalues=1;  
 // }  
38    
39  void  void
40  DataAbstract::operandCheck(const DataAbstract& right) const  DataAbstract::operandCheck(const DataAbstract& right) const
# Line 108  DataAbstract::operandCheck(const DataAbs Line 71  DataAbstract::operandCheck(const DataAbs
71  void  void
72  DataAbstract::dump(const std::string fileName) const  DataAbstract::dump(const std::string fileName) const
73  {  {
74      throw DataException("Error - DataAbstract:: dump: not implemented.");      throw DataException("Error - DataAbstract::dump: not implemented.");
75  }  }
76    
77    
# Line 119  DataAbstract::getSampleDataByTag(int tag Line 82  DataAbstract::getSampleDataByTag(int tag
82      throw DataException("Error - DataAbstract::getSampleDataByTag: Data type does not have tag values.");      throw DataException("Error - DataAbstract::getSampleDataByTag: Data type does not have tag values.");
83  }  }
84    
 // void  
 // DataAbstract::setTaggedValue(int tagKey,  
 //                              const DataArrayView& value)  
 // {  
 //     throw DataException("Error - DataAbstract::setTaggedValue: Data type does not have tag values.");  
 // }  
85    
86  void    void  
87  DataAbstract::setTaggedValue(int tagKey,  DataAbstract::setTaggedValue(int tagKey,
# Line 210  DataAbstract::setToZero() Line 167  DataAbstract::setToZero()
167  void  void
168  DataAbstract::reorderByReferenceIDs(int *reference_ids)  DataAbstract::reorderByReferenceIDs(int *reference_ids)
169  {  {
170        throw DataException("Error - DataAbstract:: cannot reorder by reference ids.");
171  }  }
172    
173    

Legend:
Removed from v.1796  
changed lines
  Added in v.1803

  ViewVC Help
Powered by ViewVC 1.1.26