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

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

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

trunk/esys2/escript/src/Data/AbstractDomain.cpp revision 82 by jgs, Tue Oct 26 06:53:54 2004 UTC temp_trunk_copy/escript/src/AbstractDomain.cpp revision 1384 by phornby, Fri Jan 11 02:29:38 2008 UTC
# Line 1  Line 1 
1  /*  
2   ******************************************************************************  /* $Id$ */
3   *                                                                            *  
4   *       COPYRIGHT  ACcESS 2004 -  All Rights Reserved                        *  /*******************************************************
5   *                                                                            *   *
6   * This software is the property of ACcESS. No part of this code              *   *           Copyright 2003-2007 by ACceSS MNRF
7   * may be copied in any form or by any means without the expressed written    *   *       Copyright 2007 by University of Queensland
8   * consent of ACcESS.  Copying, use or modification of this software          *   *
9   * by any unauthorised person is illegal unless that person has a software    *   *                http://esscc.uq.edu.au
10   * license agreement with ACcESS.                                             *   *        Primary Business: Queensland, Australia
11   *                                                                            *   *  Licensed under the Open Software License version 3.0
12   ******************************************************************************   *     http://www.opensource.org/licenses/osl-3.0.php
13  */   *
14     *******************************************************/
15  #include "escript/Data/AbstractDomain.h"  
16  #include "escript/Data/DomainException.h"  #include "AbstractDomain.h"
17  #include "escript/Data/AbstractSystemMatrix.h"  #include "DomainException.h"
18  #include "escript/Data/FunctionSpace.h"  #include "Data.h"
19    
20    using namespace std;
21    
22  namespace escript {  namespace escript {
23    
# Line 25  AbstractDomain::AbstractDomain() { Line 27  AbstractDomain::AbstractDomain() {
27  AbstractDomain::~AbstractDomain() {  AbstractDomain::~AbstractDomain() {
28  }  }
29    
30    int AbstractDomain::getMPISize() const
31    {
32       return 1;
33    }
34    int AbstractDomain::getMPIRank() const
35    {
36       return 0;
37    }
38    
39    
40  void AbstractDomain::throwStandardException(const std::string& functionName) const  void AbstractDomain::throwStandardException(const std::string& functionName) const
41  {  {
42    throw DomainException("Error - Base class function: " +    throw DomainException("Error - Base class function: " + functionName + " should not be called. Programming error.");
             functionName + " should not be called. Programming error.");  
43  }  }
44    
45  bool AbstractDomain::isValidFunctionSpaceType(int functionSpaceType) const  bool AbstractDomain::isValidFunctionSpaceType(int functionSpaceType) const
# Line 60  void AbstractDomain::write(const std::st Line 71  void AbstractDomain::write(const std::st
71    throwStandardException("AbstractDomain::write");    throwStandardException("AbstractDomain::write");
72    return;    return;
73  }  }
74    void AbstractDomain::dump(const std::string& filename) const
 void AbstractDomain::getTagList(int functionSpaceType, int** tagList, int* numTags) const  
75  {  {
76    throwStandardException("AbstractDomain::getTagList");    throwStandardException("AbstractDomain::dump");
77    return;    return;
78  }  }
79    
# Line 79  int AbstractDomain::getTagFromSampleNo(i Line 89  int AbstractDomain::getTagFromSampleNo(i
89    return 0;    return 0;
90  }  }
91    
92    int* AbstractDomain::borrowSampleReferenceIDs(int functionSpaceType) const
93    {
94      throwStandardException("AbstractDomain::borrowSampleReferenceIDs");
95      return 0;
96    }
97    
98  void AbstractDomain::setNewX(const escript::Data& arg)  void AbstractDomain::setNewX(const escript::Data& arg)
99  {  {
100    throwStandardException("AbstractDomain::setNewX");    throwStandardException("AbstractDomain::setNewX");
# Line 96  void AbstractDomain::interpolateACross(e Line 112  void AbstractDomain::interpolateACross(e
112    return;    return;
113  }  }
114    
115    escript::Data AbstractDomain::getX() const
116    {
117      throwStandardException("AbstractDomain::getX");
118      return Data();
119    }
120    
121    escript::Data AbstractDomain::getNormal() const
122    {
123      throwStandardException("AbstractDomain::getNormal");
124      return Data();
125    }
126    
127    escript::Data AbstractDomain::getSize() const
128    {
129      throwStandardException("AbstractDomain::getSize");
130      return Data();
131    }
132    
133  void AbstractDomain::setToX(escript::Data& out) const  void AbstractDomain::setToX(escript::Data& out) const
134  {  {
135    throwStandardException("AbstractDomain::setToX");    throwStandardException("AbstractDomain::setToX");
# Line 107  void AbstractDomain::setToNormal(escript Line 141  void AbstractDomain::setToNormal(escript
141    throwStandardException("AbstractDomain::setToNormal");    throwStandardException("AbstractDomain::setToNormal");
142    return;    return;
143  }  }
144    
145  void AbstractDomain::setToSize(escript::Data& out) const  void AbstractDomain::setToSize(escript::Data& out) const
146  {  {
147    throwStandardException("AbstractDomain::setToSize");    throwStandardException("AbstractDomain::setToSize");
# Line 119  void AbstractDomain::setToGradient(escri Line 154  void AbstractDomain::setToGradient(escri
154    return;    return;
155  }  }
156    
157  void AbstractDomain::saveDX(const std::string& filename,const escript::Data& arg) const  void AbstractDomain::setTags(const int functionSpaceType, const int newTag, const escript::Data& mask) const
158    {
159      throwStandardException("AbstractDomain::setTags");
160      return;
161    }
162    
163    void AbstractDomain::saveDX(const std::string& filename,const boost::python::dict& arg) const
164  {  {
165    throwStandardException("AbstractDomain::saveDX");    throwStandardException("AbstractDomain::saveDX");
166    return;    return;
167  }  }
168    
169    void AbstractDomain::saveVTK(const std::string& filename,const boost::python::dict& arg) const
170    {
171      throwStandardException("AbstractDomain::saveVTK");
172      return;
173    }
174    
175  bool AbstractDomain::probeInterpolationOnDomain(int functionSpaceType_source,int functionSpaceType_target) const  bool AbstractDomain::probeInterpolationOnDomain(int functionSpaceType_source,int functionSpaceType_target) const
176  {  {
177    throwStandardException("AbstractDomain::probeInterpolationOnDomain");    throwStandardException("AbstractDomain::probeInterpolationOnDomain");
# Line 145  bool AbstractDomain::isCellOriented(int Line 192  bool AbstractDomain::isCellOriented(int
192    
193  bool AbstractDomain::operator==(const AbstractDomain& other) const  bool AbstractDomain::operator==(const AbstractDomain& other) const
194  {  {
195    return (this==&other);    throwStandardException("AbstractDomain::operator==");
196      return false;
197  }  }
                                                                                                                                         
198  bool AbstractDomain::operator!=(const AbstractDomain& other) const  bool AbstractDomain::operator!=(const AbstractDomain& other) const
199  {  {
200    return (!operator==(other));    throwStandardException("AbstractDomain::operator!=");
201      return false;
202    }
203    
204    AbstractDomain::StatusType AbstractDomain::getStatus() const
205    {
206      throwStandardException("AbstractDomain::getStatus");
207      return 0;
208    }
209    void AbstractDomain::setTagMap(const std::string& name,  int tag)
210    {
211      throwStandardException("AbstractDomain::set TagMap is not implemented.");
212    }
213    int AbstractDomain::getTag(const std::string& name) const
214    {
215      throwStandardException("AbstractDomain::getTag is not implemented.");
216      return 0;
217  }  }
218    
219  }  // end of namespace  bool AbstractDomain::isValidTagName(const std::string& name) const
220    {
221      return false;
222    }
223    
224    std::string AbstractDomain::showTagNames() const
225    {
226      throwStandardException("AbstractDomain::showTagNames is not implemented.");
227      return string();
228    }
229    
230    
231    
232    } // end of namespace

Legend:
Removed from v.82  
changed lines
  Added in v.1384

  ViewVC Help
Powered by ViewVC 1.1.26