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

Contents of /trunk/escript/src/AbstractDomain.cpp

Parent Directory Parent Directory | Revision Log Revision Log


Revision 1137 - (show annotations)
Thu May 10 08:11:31 2007 UTC (12 years, 5 months ago) by gross
File size: 5738 byte(s)
This version passes the tests on windows except for 

   * vtk
   * netCDF

The version needs to be tested on altix and linux
1 /* $Id$ */
2 /*
3 ************************************************************
4 * Copyright 2006 by ACcESS MNRF *
5 * *
6 * http://www.access.edu.au *
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 ************************************************************
12 */
13
14 #include "AbstractDomain.h"
15 #include "DomainException.h"
16 #include "Data.h"
17
18 using namespace std;
19
20 namespace escript {
21
22 AbstractDomain::AbstractDomain() {
23 }
24
25 AbstractDomain::~AbstractDomain() {
26 }
27
28 void AbstractDomain::throwStandardException(const std::string& functionName) const
29 {
30 throw DomainException("Error - Base class function: " + functionName + " should not be called. Programming error.");
31 }
32
33 bool AbstractDomain::isValidFunctionSpaceType(int functionSpaceType) const
34 {
35 throwStandardException("AbstractDomain::isValidFunctionSpaceType");
36 return false;
37 }
38
39 std::string AbstractDomain::getDescription() const
40 {
41 throwStandardException("AbstractDomain::getDescription");
42 return "";
43 }
44
45 const
46 boost::python::str
47 AbstractDomain::str() const
48 {
49 return boost::python::str(getDescription().c_str());
50 }
51
52 std::string AbstractDomain::functionSpaceTypeAsString(int functionSpaceType) const
53 {
54 throwStandardException("AbstractDomain::functionSpaceTypeAsString");
55 return "";
56 }
57
58 int AbstractDomain::getDim() const
59 {
60 throwStandardException("AbstractDomain::getDim");
61 return 0;
62 }
63
64 void AbstractDomain::write(const std::string& filename) const
65 {
66 throwStandardException("AbstractDomain::write");
67 return;
68 }
69
70 std::pair<int,int> AbstractDomain::getDataShape(int functionSpaceCode) const
71 {
72 throwStandardException("AbstractDomain::getDataShape");
73 return std::pair<int,int>(0,0);
74 }
75
76 int AbstractDomain::getTagFromSampleNo(int functionSpaceType, int sampleNo) const
77 {
78 throwStandardException("AbstractDomain::getTagFromSampleNo");
79 return 0;
80 }
81
82 int* AbstractDomain::borrowSampleReferenceIDs(int functionSpaceType) const
83 {
84 throwStandardException("AbstractDomain::borrowSampleReferenceIDs");
85 return 0;
86 }
87
88 void AbstractDomain::setNewX(const escript::Data& arg)
89 {
90 throwStandardException("AbstractDomain::setNewX");
91 return;
92 }
93
94 void AbstractDomain::interpolateOnDomain(escript::Data& target,const escript::Data& source) const
95 {
96 throwStandardException("AbstractDomain::interpolateOnDomain");
97 return;
98 }
99 void AbstractDomain::interpolateACross(escript::Data& target, const escript::Data& source) const
100 {
101 throwStandardException("AbstractDomain::interpolateACross");
102 return;
103 }
104
105 escript::Data AbstractDomain::getX() const
106 {
107 throwStandardException("AbstractDomain::getX");
108 return Data();
109 }
110
111 escript::Data AbstractDomain::getNormal() const
112 {
113 throwStandardException("AbstractDomain::getNormal");
114 return Data();
115 }
116
117 escript::Data AbstractDomain::getSize() const
118 {
119 throwStandardException("AbstractDomain::getSize");
120 return Data();
121 }
122
123 void AbstractDomain::setToX(escript::Data& out) const
124 {
125 throwStandardException("AbstractDomain::setToX");
126 return;
127 }
128
129 void AbstractDomain::setToNormal(escript::Data& out) const
130 {
131 throwStandardException("AbstractDomain::setToNormal");
132 return;
133 }
134
135 void AbstractDomain::setToSize(escript::Data& out) const
136 {
137 throwStandardException("AbstractDomain::setToSize");
138 return;
139 }
140
141 void AbstractDomain::setToGradient(escript::Data& grad, const escript::Data& arg) const
142 {
143 throwStandardException("AbstractDomain::setToGradient");
144 return;
145 }
146
147 void AbstractDomain::setTags(const int functionSpaceType, const int newTag, const escript::Data& mask) const
148 {
149 throwStandardException("AbstractDomain::setTags");
150 return;
151 }
152
153 void AbstractDomain::saveDX(const std::string& filename,const boost::python::dict& arg) const
154 {
155 throwStandardException("AbstractDomain::saveDX");
156 return;
157 }
158
159 void AbstractDomain::saveVTK(const std::string& filename,const boost::python::dict& arg) const
160 {
161 throwStandardException("AbstractDomain::saveVTK");
162 return;
163 }
164
165 bool AbstractDomain::probeInterpolationOnDomain(int functionSpaceType_source,int functionSpaceType_target) const
166 {
167 throwStandardException("AbstractDomain::probeInterpolationOnDomain");
168 return false;
169 }
170
171 bool AbstractDomain::probeInterpolationACross(int functionSpaceType_source,const AbstractDomain& targetDomain, int functionSpaceType_target) const
172 {
173 throwStandardException("AbstractDomain::probeInterpolationACross");
174 return false;
175 }
176
177 bool AbstractDomain::isCellOriented(int functionSpaceCode) const
178 {
179 throwStandardException("AbstractDomain::isCellOriented");
180 return false;
181 }
182
183 bool AbstractDomain::operator==(const AbstractDomain& other) const
184 {
185 throwStandardException("AbstractDomain::operator==");
186 return false;
187 }
188 bool AbstractDomain::operator!=(const AbstractDomain& other) const
189 {
190 throwStandardException("AbstractDomain::operator!=");
191 return false;
192 }
193
194 AbstractDomain::StatusType AbstractDomain::getStatus() const
195 {
196 throwStandardException("AbstractDomain::getStatus");
197 return 0;
198 }
199 void AbstractDomain::setTagMap(const std::string& name, int tag)
200 {
201 throwStandardException("AbstractDomain::set TagMap is not implemented.");
202 }
203 int AbstractDomain::getTag(const std::string& name) const
204 {
205 throwStandardException("AbstractDomain::getTag is not implemented.");
206 return 0;
207 }
208
209 bool AbstractDomain::isValidTagName(const std::string& name) const
210 {
211 return false;
212 }
213
214 std::string AbstractDomain::showTagNames() const
215 {
216 throwStandardException("AbstractDomain::showTagNames is not implemented.");
217 return string();
218 }
219
220
221
222 } // end of namespace

Properties

Name Value
svn:eol-style native
svn:keywords Author Date Id Revision

  ViewVC Help
Powered by ViewVC 1.1.26