/[escript]/trunk/escript/src/DataVariable.h
ViewVC logotype

Annotation of /trunk/escript/src/DataVariable.h

Parent Directory Parent Directory | Revision Log Revision Log


Revision 478 - (hide annotations)
Tue Jan 31 02:21:49 2006 UTC (13 years, 11 months ago) by jgs
File MIME type: text/plain
File size: 3186 byte(s)
rationalise #includes

1 jgs 121 /*
2     ******************************************************************************
3     * *
4     * COPYRIGHT ACcESS 2004 - All Rights Reserved *
5     * *
6     * This software is the property of ACcESS. No part of this code *
7     * may be copied in any form or by any means without the expressed written *
8     * consent of ACcESS. Copying, use or modification of this software *
9     * by any unauthorised person is illegal unless that person has a software *
10     * license agreement with ACcESS. *
11     * *
12     ******************************************************************************
13     */
14    
15     #if !defined escript_DataVariable_20050422_H
16     #define escript_DataVariable_20050422_H
17    
18 jgs 474 #include "Data.h"
19 jgs 121
20     namespace escript {
21    
22     /**
23     \brief
24     Give a short description of what DataVariable does.
25    
26     Description:
27     Give a detailed description of DataVariable
28    
29     Template Parameters:
30     For templates describe any conditions that the parameters used in the
31     template must satisfy
32     */
33    
34     class DataVariable {
35    
36     public:
37    
38 jgs 122 enum OpCode {nullop, idop, sumop, diffop};
39 jgs 121
40     /**
41     \brief
42     Default constructor for DataVariable
43    
44     Description:
45     Default constructor for DataVariable
46    
47     Preconditions:
48     Describe any preconditions
49    
50     Throws:
51     Describe any exceptions thrown
52     */
53     DataVariable();
54    
55     /**
56     \brief
57     Constructor for DataVariable
58    
59     Description:
60     Constructor for DataVariable
61    
62     Preconditions:
63     Describe any preconditions
64    
65     Throws:
66     Describe any exceptions thrown
67     */
68 jgs 122 DataVariable(Data* data);
69 jgs 121
70     /**
71     \brief
72     Destructor for DataVariable
73    
74     Description:
75     Destructor for DataVariable
76    
77     Preconditions:
78     Describe any preconditions
79    
80     Throws:
81     Describe any exceptions thrown
82     */
83     ~DataVariable();
84    
85     /**
86     \brief
87     Evaluator for DataVariable
88    
89     Description:
90     Evaluator for DataVariable
91    
92     Preconditions:
93     Describe any preconditions
94    
95     Throws:
96     Describe any exceptions thrown
97     */
98 jgs 122 Data evaluate();
99 jgs 121
100 jgs 122 /**
101     \brief
102     Evaluator by sampleNo for DataVariable
103    
104     Description:
105     Evaluator by sampleNo for DataVariable
106    
107     Preconditions:
108     Describe any preconditions
109    
110     Throws:
111     Describe any exceptions thrown
112     */
113     double* evaluate_samp(int sampleNo);
114    
115     /**
116     \brief
117     Addor for DataVariable
118    
119     Description:
120     Addor for DataVariable
121    
122     Preconditions:
123     Describe any preconditions
124    
125     Throws:
126     Describe any exceptions thrown
127     */
128     void sum(DataVariable* right);
129    
130     /**
131     \brief
132     Diffor for DataVariable
133    
134     Description:
135     Diffor for DataVariable
136    
137     Preconditions:
138     Describe any preconditions
139    
140     Throws:
141     Describe any exceptions thrown
142     */
143     void diff(DataVariable* right);
144    
145 jgs 121 protected:
146    
147     private:
148    
149 jgs 122 OpCode op;
150 jgs 121
151 jgs 122 Data* leftArg;
152 jgs 121
153 jgs 122 DataVariable* rightArg;
154 jgs 121
155 jgs 122 double* opBuffer;
156 jgs 121
157     };
158    
159     } // end of namespace
160    
161     #endif

Properties

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

  ViewVC Help
Powered by ViewVC 1.1.26