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

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

Parent Directory Parent Directory | Revision Log Revision Log


Revision 615 - (hide annotations)
Wed Mar 22 02:12:00 2006 UTC (13 years, 11 months ago) by elspeth
File size: 1878 byte(s)
More copyright information.

1 jgs 102 //$Id$
2 jgs 121
3 jgs 82 /*
4 elspeth 615 ************************************************************
5     * Copyright 2006 by ACcESS MNRF *
6     * *
7     * http://www.access.edu.au *
8     * Primary Business: Queensland, Australia *
9     * Licensed under the Open Software License version 3.0 *
10     * http://www.opensource.org/licenses/osl-3.0.php *
11     * *
12     ************************************************************
13 jgs 82 */
14    
15 jgs 474 #include "DataEmpty.h"
16     #include "DataException.h"
17 jgs 82
18     namespace escript {
19    
20     DataEmpty::DataEmpty() :
21 jgs 102 DataAbstract(FunctionSpace())
22 jgs 82 {
23 jgs 119 resetPointDataView();
24 jgs 82 }
25    
26 jgs 102 DataEmpty::~DataEmpty()
27     {
28 jgs 82 }
29    
30 jgs 102 std::string
31     DataEmpty::toString() const
32     {
33 jgs 121 return "(Empty Data)";
34 jgs 82 }
35    
36 jgs 102 DataArrayView::ValueType::size_type
37     DataEmpty::getPointOffset(int sampleNo,
38     int dataPointNo) const
39 jgs 82 {
40     throwStandardException("getPointOffset");
41     return 0;
42     }
43    
44 jgs 102 DataArrayView
45     DataEmpty::getDataPoint(int sampleNo,
46     int dataPointNo)
47 jgs 82 {
48     throwStandardException("getDataPoint");
49     return getPointDataView();
50     }
51    
52 jgs 102 DataArrayView::ValueType::size_type
53     DataEmpty::getLength() const
54 jgs 82 {
55     return 0;
56     }
57    
58 jgs 102 DataAbstract*
59     DataEmpty::getSlice(const DataArrayView::RegionType& region) const
60 jgs 82 {
61     throwStandardException("getSlice");
62     return 0;
63     }
64    
65 jgs 102 void
66     DataEmpty::setSlice(const DataAbstract* value,
67     const DataArrayView::RegionType& region)
68 jgs 82 {
69     throwStandardException("setSlice");
70     }
71    
72 jgs 102 void
73     DataEmpty::reshapeDataPoint(const DataArrayView::ShapeType& shape)
74 jgs 82 {
75     throwStandardException("reshapeDataPoint");
76     }
77    
78 jgs 121 void
79     DataEmpty::throwStandardException(const std::string& functionName) const
80     {
81     throw DataException("Error - "+functionName+" function call invalid for DataEmpty.");
82     }
83    
84 jgs 82 } // end of namespace

Properties

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

  ViewVC Help
Powered by ViewVC 1.1.26