Subversion Repositories DevTools

Rev

Details | Last modification | View Log | RSS feed

Rev Author Line No. Line
2263 kivins 1
//## begin module%1.7%.codegen_version preserve=yes
2
//   Read the documentation to learn more about C++ code generator
3
//   versioning.
4
//## end module%1.7%.codegen_version
5
 
6
//## begin module%41F608450399.cm preserve=no
7
//## end module%41F608450399.cm
8
 
9
//## begin module%41F608450399.cp preserve=no
10
//	C O P Y R I G H T   N O T I C E
11
//	This material is confidential to ERG and may not be disclosed in whole
12
//	or in part to any third party nor used in any manner whatsoever other
13
//	than for the purposes expressly consented to by ERG in writing.
14
//
15
//	This material is also copyright and may not be reproduced, stored in a
16
//	retrieval system or transmitted in any form or by any means in whole or
17
//	in part without the express written consent of ERG.
18
//## end module%41F608450399.cp
19
 
20
//## Module: TransactionSpecificationValue%41F608450399; Pseudo Package specification
21
//## Subsystem: MASS::Dev::Tools::TxnTestManager::src%41F5A79001E4
22
//## Source file: Z:\MASS_Dev\Tools\TxnTestManager\src\TransactionSpecificationValue.h
23
 
24
#ifndef TransactionSpecificationValue_h
25
#define TransactionSpecificationValue_h 1
26
 
27
//## begin module%41F608450399.additionalIncludes preserve=no
28
//## end module%41F608450399.additionalIncludes
29
 
30
//## begin module%41F608450399.includes preserve=yes
31
#include <iostream>
32
#include <string>
33
//## end module%41F608450399.includes
34
 
35
// FieldExpression
36
#include "FieldExpression.h"
37
 
38
class TransactionSpecification;
39
class DefinedVariableTable;
40
class EvaluationContext;
41
 
42
//## begin module%41F608450399.additionalDeclarations preserve=yes
43
//## end module%41F608450399.additionalDeclarations
44
 
45
 
46
//## begin TransactionSpecificationValue%41F608450399.preface preserve=yes
47
//## end TransactionSpecificationValue%41F608450399.preface
48
 
49
//## Class: TransactionSpecificationValue%41F608450399; private
50
//	A value of a field in a transaction specification.  During transaction
51
//	generation, specifications are instantiated by evaluating its values.
52
//## Category: TransactionTestManager::Transaction Specification%41FD9D7902B3
53
//## Subsystem: MASS::Dev::Tools::TxnTestManager::src%41F5A79001E4
54
//## Persistence: Transient
55
//## Cardinality/Multiplicity: n
56
 
57
 
58
 
59
//## Uses: <unnamed>%420472570148;Iteration { -> }
60
//## Uses: <unnamed>%4204725F0233;TestScenario { -> }
61
//## Uses: <unnamed>%4204728C01D5;XMLSchema::IXmlSchemaWrapperSchema { -> }
62
//## Uses: <unnamed>%420AD8DF0202;DefinedVariableTable { -> F}
63
//## Uses: <unnamed>%421176A70068;EvaluationContext { -> F}
64
 
65
class TransactionSpecificationValue 
66
{
67
  //## begin TransactionSpecificationValue%41F608450399.initialDeclarations preserve=yes
68
  //## end TransactionSpecificationValue%41F608450399.initialDeclarations
69
 
70
  public:
71
    //## Constructors (specified)
72
      //## Operation: TransactionSpecificationValue%420429860176
73
      //	This constructor creates an instance for a given xpath.
74
      TransactionSpecificationValue (const std::string &xPath, 	// The xpath of the field.
75
      TransactionSpecification& transaction	// The transaction for which this field is defined.  While we do not accept
76
      	// ownership over this instance, we do assume its validity for the remainder
77
      	// of our lifetime.
78
      );
79
 
80
      //## Operation: TransactionSpecificationValue%41F705C90020
81
      //	This constructor expects values for all attributes.
82
      TransactionSpecificationValue (const std::string &xPath, 	// The xpath of the field.
83
      const std::string &value, 	// The value.
84
      const bool &obsolete	// Of value true when the value is obsolete, and of value false otherwise.
85
      );
86
 
87
    //## Destructor (generated)
88
      virtual ~TransactionSpecificationValue();
89
 
90
 
91
    //## Other Operations (specified)
92
      //## Operation: evaluate%420AC7E6015D
93
      //	Evaluate the expression of this field, and evaluate to true, or to false
94
      //	when any expression cannot be evaluated.
95
      const bool evaluate (std::string &value, 	// The resulting value.
96
      const bool &sideEffect, 	// When true, evaluation is allowed to have side effects, otherwise side
97
      	// effects must be suppressed.  For example, when true, a call to a sequence
98
      	// generator may allocate a new number from the sequence: when false, the call
99
      	// must not change the sate of the sequence generator.
100
      	// 
101
      	// One usage of this: when generating a transaction side effects are allowed,
102
      	// when rendering the hint to display for a field value side effects are not
103
      	// allowed.
104
      EvaluationContext& evaluationContext, 	// The evaluation context.
105
      bool &postponed	// Set the actual argument to true when evaluation is postponed, and to false
106
      	// otherwise.
107
      );
108
 
109
      //## Operation: getExpression%41F7167C0014
110
      //	Evaluate to the expression of this instance.
111
      const std::string & getExpression () const;
112
 
113
      //## Operation: getXPath%41F766AF01D4
114
      //	Evaluate to the xpath of this instance.
115
      const std::string & getXPath () const;
116
 
117
      //## Operation: isMarked%41F7058D0276
118
      //	Evaluate to true when this value is marked, and to false otherwise.
119
      const bool isMarked () const;
120
 
121
      //## Operation: isObsolete%41F7228502A8
122
      //	Evaluate to true when this value is obsolete, and to false otherwise.
123
      const bool isObsolete () const;
124
 
125
      //## Operation: mark%41F705930342
126
      //	Mark this value.
127
      void mark ();
128
 
129
      //## Operation: setExpression%42042A51030C
130
      //	Set the expression of this instance, and evaluate to the resulting value.
131
      const std::string & setExpression (const std::string &value	// The value.
132
      );
133
 
134
      //## Operation: unmark%41F7070602A0
135
      //	Unmark this value.
136
      void unmark ();
137
 
138
    // Additional Public Declarations
139
      //## begin TransactionSpecificationValue%41F608450399.public preserve=yes
140
      //## end TransactionSpecificationValue%41F608450399.public
141
 
142
  protected:
143
    // Additional Protected Declarations
144
      //## begin TransactionSpecificationValue%41F608450399.protected preserve=yes
145
      //## end TransactionSpecificationValue%41F608450399.protected
146
 
147
  private:
148
    //## Constructors (generated)
149
      TransactionSpecificationValue();
150
 
151
      TransactionSpecificationValue(const TransactionSpecificationValue &right);
152
 
153
    //## Assignment Operation (generated)
154
      TransactionSpecificationValue & operator=(const TransactionSpecificationValue &right);
155
 
156
    // Data Members for Class Attributes
157
 
158
      //## Attribute: marked%41F704800286
159
      //	Of value true when this field is marked, and false otherwise.
160
      //## begin TransactionSpecificationValue::marked%41F704800286.attr preserve=no  private: bool {VA} false
161
      bool m_marked;
162
      //## end TransactionSpecificationValue::marked%41F704800286.attr
163
 
164
      //## Attribute: obsolete%41F7222B01BE
165
      //	Of value true when the value is obsolete, and of value false otherwise.
166
      //## begin TransactionSpecificationValue::obsolete%41F7222B01BE.attr preserve=no  private: bool {VA} 
167
      bool m_obsolete;
168
      //## end TransactionSpecificationValue::obsolete%41F7222B01BE.attr
169
 
170
      //## Attribute: inPayload%41F763980317
171
      //	When true, the value is in the payload, otherwise it is in the header.
172
      //## begin TransactionSpecificationValue::inPayload%41F763980317.attr preserve=no  private: bool {VA} 
173
      bool m_inPayload;
174
      //## end TransactionSpecificationValue::inPayload%41F763980317.attr
175
 
176
      //## Attribute: xPath%41F7044B0228
177
      //	The xpath of the field.
178
      //## begin TransactionSpecificationValue::xPath%41F7044B0228.attr preserve=no  private: std::string {VA} 
179
      std::string m_xPath;
180
      //## end TransactionSpecificationValue::xPath%41F7044B0228.attr
181
 
182
    // Data Members for Associations
183
 
184
      //## Association: TransactionTestManager::Transaction Generation::<unnamed>%4204701D02DA
185
      //## Role: TransactionSpecificationValue::transaction%4204701E002B
186
      //	The transaction for which this field is defined.  While we do not accept
187
      //	ownership over this instance, we do assume its validity for the remainder of
188
      //	our lifetime.
189
      //## begin TransactionSpecificationValue::transaction%4204701E002B.role preserve=no  private: TransactionSpecification {1 -> 1RFHAN}
190
      TransactionSpecification *m_transaction;
191
      //## end TransactionSpecificationValue::transaction%4204701E002B.role
192
 
193
      //## Association: TransactionTestManager::Symbol Table::<unnamed>%420AC6610015
194
      //## Role: TransactionSpecificationValue::expression%420AC661015D
195
      //	expression
196
      //## begin TransactionSpecificationValue::expression%420AC661015D.role preserve=no  private: FieldExpression {1 -> 1VHgAN}
197
      FieldExpression m_expression;
198
      //## end TransactionSpecificationValue::expression%420AC661015D.role
199
 
200
    // Additional Private Declarations
201
      //## begin TransactionSpecificationValue%41F608450399.private preserve=yes
202
      //## end TransactionSpecificationValue%41F608450399.private
203
 
204
  private: //## implementation
205
    // Additional Implementation Declarations
206
      //## begin TransactionSpecificationValue%41F608450399.implementation preserve=yes
207
      //## end TransactionSpecificationValue%41F608450399.implementation
208
 
209
};
210
 
211
//## begin TransactionSpecificationValue%41F608450399.postscript preserve=yes
212
//## end TransactionSpecificationValue%41F608450399.postscript
213
 
214
// Class TransactionSpecificationValue 
215
 
216
//## begin module%41F608450399.epilog preserve=yes
217
//## end module%41F608450399.epilog
218
 
219
 
220
#endif