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

Annotation of /trunk/escript/src/DataEmpty.cpp

Parent Directory Parent Directory | Revision Log Revision Log


Revision 119 - (hide annotations)
Tue Apr 12 04:45:05 2005 UTC (14 years, 5 months ago) by jgs
Original Path: trunk/esys2/escript/src/Data/DataEmpty.cpp
File size: 2336 byte(s)
*** empty log message ***

1 jgs 102 //$Id$
2 jgs 82 /*
3     ******************************************************************************
4     * *
5     * COPYRIGHT ACcESS 2004 - All Rights Reserved *
6     * *
7     * This software is the property of ACcESS. No part of this code *
8     * may be copied in any form or by any means without the expressed written *
9     * consent of ACcESS. Copying, use or modification of this software *
10     * by any unauthorised person is illegal unless that person has a software *
11     * license agreement with ACcESS. *
12     * *
13     ******************************************************************************
14     */
15    
16     #include "escript/Data/DataEmpty.h"
17     #include "escript/Data/DataException.h"
18    
19     namespace escript {
20    
21     DataEmpty::DataEmpty() :
22 jgs 102 DataAbstract(FunctionSpace())
23 jgs 82 {
24 jgs 119 resetPointDataView();
25 jgs 82 }
26    
27 jgs 102 DataEmpty::~DataEmpty()
28     {
29 jgs 82 }
30    
31 jgs 102 std::string
32     DataEmpty::toString() const
33     {
34 jgs 82 return "Empty Data.";
35     }
36    
37 jgs 102 void
38     DataEmpty::throwStandardException(const std::string& functionName) const
39 jgs 82 {
40     throw DataException("Error - "+functionName+" function call invalid for DataEmpty.");
41     }
42    
43 jgs 102 DataArrayView::ValueType::size_type
44     DataEmpty::getPointOffset(int sampleNo,
45     int dataPointNo) const
46 jgs 82 {
47     throwStandardException("getPointOffset");
48     return 0;
49     }
50    
51 jgs 102 double*
52     DataEmpty::getSampleDataByTag(int tag)
53 jgs 82 {
54     throwStandardException("getSampleDataByTag");
55     return 0;
56     }
57    
58 jgs 102 DataArrayView
59     DataEmpty::getDataPoint(int sampleNo,
60     int dataPointNo)
61 jgs 82 {
62     throwStandardException("getDataPoint");
63     return getPointDataView();
64     }
65    
66 jgs 102 DataArrayView::ValueType::size_type
67     DataEmpty::getLength() const
68 jgs 82 {
69     return 0;
70     }
71    
72 jgs 102 DataAbstract*
73     DataEmpty::getSlice(const DataArrayView::RegionType& region) const
74 jgs 82 {
75     throwStandardException("getSlice");
76     return 0;
77     }
78    
79 jgs 102 void
80     DataEmpty::setSlice(const DataAbstract* value,
81     const DataArrayView::RegionType& region)
82 jgs 82 {
83     throwStandardException("setSlice");
84     }
85    
86 jgs 102 void
87     DataEmpty::reshapeDataPoint(const DataArrayView::ShapeType& shape)
88 jgs 82 {
89     throwStandardException("reshapeDataPoint");
90     }
91    
92     } // end of namespace

Properties

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

  ViewVC Help
Powered by ViewVC 1.1.26