MOOSE - Multiscale Object Oriented Simulation Environment
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros
Annotator.cpp
Go to the documentation of this file.
1 /**********************************************************************
2 ** This program is part of 'MOOSE', the
3 ** Messaging Object Oriented Simulation Environment.
4 ** Copyright (C) 2003-2012 Upinder S. Bhalla. and NCBS
5 ** It is made available under the terms of the
6 ** GNU Lesser General Public License version 2.1
7 ** See the file COPYING.LIB for the full notice.
8 **********************************************************************/
9 #include "header.h"
10 #include "Annotator.h"
11 
13 {
15  // Field Definitions
18  "x",
19  "x field. Typically display coordinate x",
22  );
24  "y",
25  "y field. Typically display coordinate y",
28  );
30  "z",
31  "z field. Typically display coordinate z",
34  );
35 
37  "notes",
38  "A string to hold some text notes about parent object",
41  );
42 
44  "color",
45  "A string to hold a text string specifying display color."
46  "Can be a regular English color name, or an rgb code rrrgggbbb",
49  );
50 
51  static ValueFinfo< Annotator, string > textColor(
52  "textColor",
53  "A string to hold a text string specifying color for text label"
54  "that might be on the display for this object."
55  "Can be a regular English color name, or an rgb code rrrgggbbb",
58  );
59 
61  "icon",
62  "A string to specify icon to use for display",
65  );
66  static ValueFinfo< Annotator, string > solver(
67  "solver",
68  "A string to specify solver to store for Gui",
71  );
72  static ValueFinfo< Annotator, double > runtime(
73  "runtime",
74  "runtime field. Store runtime ",
77  );
78  static ValueFinfo< Annotator, string > dirpath(
79  "dirpath",
80  "directory path for Gui",
83  );
84  static ValueFinfo< Annotator, string > modeltype(
85  "modeltype",
86  "model type ",
89  );
90  static Finfo* annotatorFinfos[] = {
91  &x, // Value
92  &y, // Value
93  &z, // Value
94  &notes, // Value
95  &color, // Value
96  &textColor, // Value
97  &icon, // Value
98  &solver,
99  &runtime,
100  &dirpath,
101  &modeltype,
102  };
103 
104  static Dinfo< Annotator > dinfo;
105  static Cinfo annotatorCinfo (
106  "Annotator",
108  annotatorFinfos,
109  sizeof( annotatorFinfos ) / sizeof ( Finfo* ),
110  &dinfo
111  );
112 
113  return &annotatorCinfo;
114 }
115 
117 
119  : x_( 0.0 ), y_( 0.0 ), z_( 0.0 ),
120  notes_( "" ), color_( "white" ), textColor_( "black" ),
121  icon_( "sphere" ),solver_( "ee"),runtime_(100.0),dirpath_(""),modeltype_("")
122 {
123  ;
124 }
125 
126 double Annotator::getX() const
127 {
128  return x_;
129 }
130 
131 void Annotator::setX( double v )
132 {
133  x_ = v;
134 }
135 
136 double Annotator::getY() const
137 {
138  return y_;
139 }
140 
141 void Annotator::setY( double v )
142 {
143  y_ = v;
144 }
145 
146 double Annotator::getZ() const
147 {
148  return z_;
149 }
150 
151 void Annotator::setZ( double v )
152 {
153  z_ = v;
154 }
155 
156 string Annotator::getNotes() const
157 {
158  return notes_;
159 }
160 
161 void Annotator::setNotes( string v )
162 {
163  notes_ = v;
164 }
165 
166 string Annotator::getColor() const
167 {
168  return color_;
169 }
170 
171 void Annotator::setColor( string v )
172 {
173  color_ = v;
174 }
175 
177 {
178  return textColor_;
179 }
180 
181 void Annotator::setTextColor( string v )
182 {
183  textColor_ = v;
184 }
185 
186 string Annotator::getIcon() const
187 {
188  return icon_;
189 }
190 
191 void Annotator::setIcon( string v )
192 {
193  icon_ = v;
194 }
195 string Annotator::getSolver() const
196 {
197  return solver_;
198 }
199 
200 void Annotator::setSolver( string v )
201 {
202  solver_ = v;
203 }
204 double Annotator::getRuntime() const
205 {
206  return runtime_;
207 }
208 
209 void Annotator::setRuntime( double v )
210 {
211  runtime_ = v;
212 }
213 string Annotator::getdirpath() const
214 {
215  return dirpath_;
216 }
217 
218 void Annotator::setdirpath( string v )
219 {
220  dirpath_ = v;
221 }
223 {
224  return modeltype_;
225 }
226 
227 void Annotator::setmodeltype( string v )
228 {
229  modeltype_ = v;
230 }
string textColor_
Definition: Annotator.h:50
static const Cinfo * initCinfo()
Definition: Annotator.cpp:12
static const Cinfo * annotatorCinfo
Definition: Annotator.cpp:116
Definition: Dinfo.h:60
string getColor() const
Definition: Annotator.cpp:166
string getSolver() const
Definition: Annotator.cpp:195
void setTextColor(string v)
Definition: Annotator.cpp:181
void setNotes(string v)
Definition: Annotator.cpp:161
double getZ() const
Definition: Annotator.cpp:146
string getmodeltype() const
Definition: Annotator.cpp:222
string getdirpath() const
Definition: Annotator.cpp:213
string dirpath_
Definition: Annotator.h:54
void setIcon(string v)
Definition: Annotator.cpp:191
double runtime_
Definition: Annotator.h:53
string getTextColor() const
Definition: Annotator.cpp:176
double y_
Definition: Annotator.h:46
double getY() const
Definition: Annotator.cpp:136
string icon_
Definition: Annotator.h:51
void setColor(string v)
Definition: Annotator.cpp:171
string modeltype_
Definition: Annotator.h:55
void setSolver(string v)
Definition: Annotator.cpp:200
void setmodeltype(string v)
Definition: Annotator.cpp:227
double z_
Definition: Annotator.h:47
double x_
Definition: Annotator.h:45
string notes_
Definition: Annotator.h:48
double getX() const
Definition: Annotator.cpp:126
string solver_
Definition: Annotator.h:52
string getNotes() const
Definition: Annotator.cpp:156
void setRuntime(double v)
Definition: Annotator.cpp:209
static const Cinfo * initCinfo()
Definition: Neutral.cpp:16
string getIcon() const
Definition: Annotator.cpp:186
void setX(double v)
Definition: Annotator.cpp:131
Definition: Cinfo.h:18
double getRuntime() const
Definition: Annotator.cpp:204
void setdirpath(string v)
Definition: Annotator.cpp:218
void setY(double v)
Definition: Annotator.cpp:141
void setZ(double v)
Definition: Annotator.cpp:151
Definition: Finfo.h:12
string color_
Definition: Annotator.h:49