Escript  Revision_4320
DataEmpty.h
Go to the documentation of this file.
1 
2 /*****************************************************************************
3 *
4 * Copyright (c) 2003-2013 by University of Queensland
5 * http://www.uq.edu.au
6 *
7 * Primary Business: Queensland, Australia
8 * Licensed under the Open Software License version 3.0
9 * http://www.opensource.org/licenses/osl-3.0.php
10 *
11 * Development until 2012 by Earth Systems Science Computational Center (ESSCC)
12 * Development since 2012 by School of Earth Sciences
13 *
14 *****************************************************************************/
15 
16 
17 #if !defined escript_DataEmpty_20040726_H
18 #define escript_DataEmpty_20040726_H
19 #include "system_dep.h"
20 
21 #include "DataReady.h"
22 
23 namespace escript {
24 
33 class DataEmpty : public DataReady {
34 typedef DataReady parent;
35  public:
36 
46  DataEmpty();
47 
53  virtual
54  ~DataEmpty();
55 
61  virtual
62  std::string
63  toString() const;
64 
69  virtual
71  deepCopy();
72 
73 
83  virtual
85  getPointOffset(int sampleNo,
86  int dataPointNo) const;
87 
89  virtual
91  getPointOffset(int sampleNo,
92  int dataPointNo);
93 
100  virtual
102  getLength() const;
103 
112  virtual
113  DataAbstract*
114  getSlice(const DataTypes::RegionType& region) const;
115 
126  virtual
127  void
128  setSlice(const DataAbstract* value,
129  const DataTypes::RegionType& region);
130 
137  int
138  matrixInverse(DataAbstract* out) const;
139 
140  void
141  dump(const std::string fileName) const;
142 
144  bool
145  hasNaN() const
146  {
147  return false;
148  }
149  protected:
150 
155  virtual DataTypes::ValueType&
156  getVectorRW();
157 
158 
160  virtual const DataTypes::ValueType&
161  getVectorRO() const;
162 
163 
164  private:
165 
166 // /**
167 /* \brief
168  Throw a standard exception. This function is called if an attempt
169  is made to use functions of DataEmpty that are not valid.*/
170 // */
171 // void
172 // throwStandardException(const std::string& functionName) const;
173 
174 };
175 
176 } // end of namespace
177 
178 #endif