0% found this document useful (0 votes)
333 views220 pages

B66043 C++ Class Reference

C++ Class Reference

Uploaded by

Miroserh
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
333 views220 pages

B66043 C++ Class Reference

C++ Class Reference

Uploaded by

Miroserh
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 220

$375$Œ Advance ADE

C++ Class Reference

B006-6043-B000
March 2003
The product described in this publication is a licensed product of NCR Corporation.

APTRA is a trademark of NCR Corporation.


Microsoft, Windows, Windows NT, Windows XP, Visual C++, Visual Basic, and ActiveX are registered
trademarks of Microsoft Corporation in the United States and/or other countries.
Adobe, Acrobat and Reader are either registered trademarks or trademarks of Adobe Systems
Incorporated in the United States and/or other countries.

Other brand or product names are trademarks or registered trademarks of their respective companies
or organisations.

This publication supports release 01.04.00 of the NCR APTRA Advance ADE product.

It is the policy of NCR Corporation (NCR) to improve products as new technology, components,
software, and firmware become available. NCR, therefore, reserves the right to change specifications
without prior notice.

All features, functions, and operations described herein may not be marketed by NCR in all parts of
the world. In some instances, photographs are of equipment prototypes. Therefore, before using this
document, consult with your NCR representative or NCR office for information that is applicable and
current.

To maintain the quality of our publications, we need your comments on the accuracy, clarity,
organization, and value of this book.

Address correspondence to:

NCR Financial Solutions Group Ltd.


Information Solutions Feedback
Kingsway West
Dundee
Scotland
DD2 3XX

© 1998 - 2003
By NCR Corporation
Dayton, Ohio U.S.A.
All Rights Reserved.
Federal Communications
Commission (FCC) Radio
Frequency Interference
Statement

Note: This equipment has been tested and found to


comply with the limits for a Class A digital device,
pursuant to Part 15 of the FCC Rules. These limits are
designed to provide reasonable protection against
harmful interference when the equipment is operated
in a commercial environment. This equipment
generates, uses, and can radiate radio frequency energy
and, if not installed and used in accordance with the
instruction manual, may cause harmful interference to
radio communications. Operation of this equipment in
a residential area is likely to cause harmful
interference in which case the user will be required to
correct the interference at his own expense.

This digital apparatus does not exceed the Class A


Canadian Class A limits for radio noise emissions from digital apparatus
Device Declaration set out in the Radio Interference Regulations of the
Canadian Department of Communications.
Le présent appareil numérique n’émet pas de bruits
radioélectriques dépassant les limites applicables aux
appareils numériques de la classe A prescrites dans le
Réglement sur le brouillage radioélectrique édicté par
le ministère des Communications du Canada.

APTRA Advance ADE, C++ Class Reference i


This equipment must be installed and used in strict
Information to User accordance with the manufacturer’s instructions.
However, there is no guarantee that interference to radio
communications will not occur in a particular
commercial installation. If this equipment does cause
interference, which can be determined by turning the
equipment off and on, the user is encouraged to consult
an NCR service representative immediately.

Caution NCR is not responsible for any radio or television


interference caused by unauthorised modifications of
this equipment or the substitution or attachment of
connecting cables and equipment other than those
specified by NCR. Such unauthorized modifications,
substitutions, or attachments may void the user’s
authority to operate the equipment. The correction of
interference caused by such unauthorized modifications,
substitutions, or attachments will be the responsibility of
the user.

ii APTRA Advance ADE, C++ Class Reference


Revision Record

Date Page Description of Change

Apr. 98 All New Publication.

Mar. 00 All Changed SSDS to Advance ADE.


Changed Platform to Advance XFS.

Front Changed document number.


and Back

App E Updated related documentation for this


release of Advance ADE.

Glossary New entry for Advance XFS.

Mar. 03 All Updated to support APTRA Advance


ADE release 01.04.00.
Added ‘APTRA Advance ADE’ to footer.

D-1 Changed Advance XFS to Self-Service


Support.

Appx. E Updated and added documentation


numbers.

E-4 Removed Database help.

Glossary Changed Advance XFS to Self-Service


Support.

APTRA Advance ADE, C++ Class Reference iii


iv APTRA Advance ADE, C++ Class Reference
Table of Contents

Contents

Preface .................................................................................xiii
About this Publication ................................................xiii
Who should read this Publication?...........................xiii
What experience should I have? ...............................xiii
What is in this Publication? .......................................xiii
Definitions and Conventions Used...........................xiv
Support Information ....................................................xv

Class Descriptions

Class Descriptions

Introduction .........................................Class Descriptions-v


Class Hierarchy.............................Class Descriptions-v

Chapter 1
Common Utilities Classes

Overview.............................................................................1-1
mEvent (abstract) ...............................................................1-2
mString ................................................................................1-4

APTRA Advance ADE, C++ Class Reference v


Table of Contents

Chapter 2
Runtime Core Classes

Overview............................................................................. 2-1
mConcreteWorker (abstract)............................................ 2-2
mDoer (abstract) ................................................................ 2-4
mEventContext (abstract) ............................................... 2-12
mGetter (abstract) ............................................................ 2-19
mHandle ........................................................................... 2-23
mHandleGetter (abstract)............................................... 2-30
mHandlePutter (abstract) ............................................... 2-33
mIntegerGetter (abstract) ............................................... 2-36
mIntegerPutter (abstract)................................................ 2-39
mPutter (abstract) ............................................................ 2-43
mRealGetter (abstract) .................................................... 2-47
mRealPutter (abstract) .................................................... 2-50
mSignal.............................................................................. 2-53
mSignaller (abstract) ....................................................... 2-61
mStringGetter (abstract) ................................................. 2-62
mStringPutter (abstract) ................................................. 2-66
mTBasicWorkGroup (template) .................................... 2-69
mTDoerWorkGroup (template)..................................... 2-73
mUserEvent ...................................................................... 2-83
mWorkContext................................................................. 2-87
mWorkGroup (abstract) ................................................. 2-96

vi APTRA Advance ADE, C++ Class Reference


Table of Contents

Appendix A
Appendices Data Types

Overview............................................................................A-1
Advance ADE Simple Data Types..................................A-2
SignalPriorityRef ...............................................................A-3
UserMsg .............................................................................A-5

Appendix B
Error Messages

Overview............................................................................ B-1
Invalid Data Conversion .................................................. B-2

Appendix C
Advance ADE Class Names and Identifiers

Overview............................................................................ C-1
Advance ADE Class Names and Identifiers ................. C-2

Appendix D
ADI-2 Extensions

Overview............................................................................D-1
ADI_M_SETUP_MONITOR............................................D-2

APTRA Advance ADE, C++ Class Reference vii


Table of Contents

Appendix E
Related Documentation

Overview.............................................................................E-1
NCR Advance ADE Documentation ..............................E-2
Other NCR Documentation..............................................E-5

Glossary
Glossary Glossary ................................................................ Glossary-1

Index
Index Index............................................................................ Index-1

User Feedback Form

viii APTRA Advance ADE, C++ Class Reference


List of Figures

List of Figures

Figure 1 Advance ADE Supplied Classes


Hierarchy ......................Class Descriptions-v

Chapter 1
Common Utilities Classes

Chapter 2
Runtime Core Classes

Appendix A
Data Types

Appendix B
Error Messages

Appendix C
Advance ADE Class Names and Identifiers

APTRA Advance ADE, C++ Class Reference ix


List of Figures

Appendix D
ADI-2 Extensions

Appendix E
Related Documentation

x APTRA Advance ADE, C++ Class Reference


List of Tables

List of Tables

Chapter 1
Common Utilities Classes

Chapter 2
Runtime Core Classes

Appendix A
Data Types

Appendix B
Error Messages

Appendix C
Advance ADE Class Names and Identifiers

Table C-1 Advance ADE Class Names and


Identifiers ....................................................C-2

APTRA Advance ADE, C++ Class Reference xi


List of Tables

Appendix D
ADI-2 Extensions

Appendix E
Related Documentation

xii APTRA Advance ADE, C++ Class Reference


Preface
Preface

Preface

This publication contains information on those C++


About this Publication classes supplied with APTRA Advance ADE which are
published for use in extending the functionality of the
supplied Advance ADE classes.
This information is intended to assist in the creation of
new Worker classes which use, or subclass from, the
published classes.

This publication is intended for C++ designers and


Who should read this programmers.
Publication? It should be used in conjunction with the APTRA
Advance ADE, Programmer’s Guide.

In addition to familiarity with Advance ADE, you need a


What experience thorough understanding of the principles and practice of
should I have? Object Oriented design and programming in C++.

This publication contains the following information:-


What is in this
Publication? The Class Descriptions section, comprising:
Chapter 1, “Common Utilities Classes”, which presents
information about the published utility classes.
Chapter 2, “Runtime Core Classes”, which presents
information about the published core classes.
The Appendices section, comprising:
Appendix A, “Data Types”, which describes the data
types used by the supplied classes.

APTRA Advance ADE, C++ Class Reference xiii


Preface
Preface

Appendix B, “Error Messages”, which lists and


describes the error messages produced by the supplied
classes.
Appendix C, “Advance ADE Class Names and
Identifiers”, which lists the class names and IDs of the
supplied classes.
Appendix D, “ADI-2 Extensions”, which lists the ADI-2
Extensions introduced by Advance ADE.
Appendix E, “Related Documentation”, which
identifies other documentation which is available to help
you develop Advance ADE Applications.
The Glossary, which lists and explains terms used in this
publication in alphabetical order.
The Index, which provides a classified list of topics and
items of information in this publication, with page
references.

The following conventions are used in this publication:


Definitions and
Conventions Used source Class and method declarations.
code

xiv APTRA Advance ADE, C++ Class Reference


Preface
Preface

If you have a problem using the Advance ADE software,


Support Information do the following until the problem is fixed:
1 Refer to Appendix A, “Data Types” to see if you can
resolve the problem yourself.

2 Contact your internal support person for help.

3 Contact your local NCR representative.


NCR provides a wide range of support programmes. For
more information, contact your local Account Team.
Should you have any problems using this guide, refer to
the User Feedback Form at the back of this guide, where
you will find our e-mail address. Please take the time to
reply; your comments are valued.

APTRA Advance ADE, C++ Class Reference xv


Preface
Preface

xvi APTRA Advance ADE, C++ Class Reference


Class Descriptions

Introduction Class Descriptions-v

Chapter 1 Common Utilities Classes

Chapter 2 Runtime Core Classes

APTRA Advance ADE, C++ Class Reference


APTRA Advance ADE, C++ Class Reference
Class Descriptions
Overview

Overview

This Section contains information on the published


classes in Advance ADE.
The Introduction provides general information about
the classes and the ways in which they can be utilised.
Each chapter contains an Overview followed by class
descriptions which are identified and ordered by Class
Identifier.
Each class description consists of an overall description
of the class, including a (partial) class declaration, its use,
functionality, requirements, and so on, followed by
detailed descriptions of the class methods available to
users.
The heading of a method description may be in one of
the following forms:
● The method name, for example “GetID”
● The role of the method, for example “Constructor”
● Where more than one form of the method exists, the
method name or role followed by a descriptive term;
for example, “Constructor - Default”, “GetData -
Wide Character”.
The information in this section should be used in APTRA
Advance ADE, Programmer’s Guide.
Any classes not included in this publication are reserved
by NCR.

APTRA Advance ADE, C++ Class Reference Class Descriptions-iii


Class Descriptions
Overview

Class Descriptions-iv APTRA Advance ADE, C++ Class Reference


Class Descriptions
Introduction

Introduction

User-created Worker Classes can use the concrete


classes, and both use and inherit from the abstract
classes, described in this Section.
The information in the abstract class descriptions enables
specialisation by inheritance to be implemented. For
information on how these classes may be used, refer to
the APTRA Advance ADE, Programmer’s Guide.

The class hierarchy of the Worker Classes supplied with


Class Hierarchy Advance ADE is shown in Figure 1.

Figure 1
Advance ADE Supplied Classes mConcreteWorker (abstract)
Hierarchy mEvent (abstract)
mUserEvent
mEventContext (abstract)
mGetter (abstract)
mHandleGetter (abstract)
mStringGetter (abstract)
mRealGetter (abstract)
mIntegerGetter (abstract)
mHandle
mPutter (abstract)
mHandlePutter (abstract)
mIntegerPutter (abstract)
mRealPutter (abstract)
mStringPutter (abstract)
mSignal

APTRA Advance ADE, C++ Class Reference Class Descriptions-v


Class Descriptions
Introduction

mSignaller (abstract)
mDoer (abstract)
mString
mTBasicWorkGroup (template)
mTDoerWorkGroup (template)
mWorkContext
mWorkGroup (abstract)

Class Descriptions-vi APTRA Advance ADE, C++ Class Reference


Table of Contents
Common Utilities Classes

Chapter 1
Common Utilities Classes

Overview 1-1

mEvent (abstract) 1-2

mString 1-4

APTRA Advance ADE, C++ Class Reference


Table of Contents
Common Utilities Classes
Common Utilities Classes
1

Overview

Overview 1

This chapter contains class descriptions for the published utility classes in
Advance ADE.

APTRA Advance ADE, C++ Class Reference 1-1


Common Utilities Classes
mEvent (abstract)

mEvent (abstract) 1

USE
To encapsulate all Events generated by the operating system and the Workers
themselves, in a C++ class.

CLASS DECLARATION

class mEvent
{
protected:
mEvent( void );
public:
unsigned long GetID(void ) const;
};

CLASS DESCRIPTION
The mEvent (abstract) class is the base class for all the types of Event that the
Worker Classes must handle.
The data associated with the Event is stored in the Event object. Each type of
Event must supply its own methods to query its own particular data.

SEE ALSO
mEventContext (abstract), page 2-12

REQUIREMENTS
mcore.h, mcore.lib

SUPERCLASSES
None

CLASS METHODS
Constructor — Default, page 1-3

1-2 APTRA Advance ADE, C++ Class Reference


Common Utilities Classes
mEvent (abstract)

GetID, page 1-3

Constructor — Default 1

USE
To create an mEvent object without any supplied data.

SYNOPSIS
mEvent( void );

METHOD DESCRIPTION
See USE above.

GetID 1

USE
To obtain the unique ID of the mEvent object.

SYNOPSIS
unsigned long GetID( void ) const;

RETURN VALUE
The unique ID of the mEvent object as an unsigned long integer.

METHOD DESCRIPTION
This accessor method returns the unique ID of the mEvent object, which is
assigned when the object is created.
This method should not be redefined.

APTRA Advance ADE, C++ Class Reference 1-3


Common Utilities Classes
mString

mString 1

USE
To define an object containing a character array which represents a string.

CLASS DECLARATION

class IMP_OR_EXP mString


{
public:
mString();
mString( const TCHAR *pChar,
const UINT Offset = 0,
const UINT Length = SHRT_MAX
);
mString( const char *pChar,
const UINT Offset = 0,
const UINT Length = SHRT_MAX
);
mString( const mString &String );
mString( const long Integer );
mString( const double Real );
mString( const TCHAR Char );
mString( const char Char );
mString( const BYTE *pByte,
const UINT NumChars,
const UINT BytesPerChar
);

~mString();

int ReplaceStr( const mString &SearchString,


const mString &ReplaceString,
const UINT Offset = 0
);

1-4 APTRA Advance ADE, C++ Class Reference


Common Utilities Classes
mString

mString &InsertStr( const mString &String,


const UINT Offset = 0
);
mString &InsertStr( const TCHAR *pString,
const UINT Offset = 0
);
IMP_OR_EXP friend int FindStr(const mString &StringToBeSearched,
const mString &SearchString,
const UINT Offset = 0
);
IMP_OR_EXP friend int FindStr(const mString &StringToBeSearched,
const TCHAR *pSearchString,
const UINT Offset = 0
);
IMP_OR_EXP friend mString Parse( mString &String,
const mString &Delimiter
);
IMP_OR_EXP friend mString Parse( mString &String,
const TCHAR *pDelimiter
);
IMP_OR_EXP friend mString SubStr( const mString &String,
const UINT Offset = 0,
const UINT Length = SHRT_MAX
);
IMP_OR_EXP friend mString SubStr( const TCHAR *pString,
const UINT Offset = 0,
const UINT Length = SHRT_MAX
);
char *Export( char *pBuffer,
const UINT Offset = 0,
const UINT NumChars = SHRT_MAX
) const;
WCHAR *Export( WCHAR *pBuffer,
const UINT Offset = 0,
const UINT NumChars = SHRT_MAX
) const;
BYTE *Export( BYTE *pBuffer,
const UINT Offset = 0,
const UINT NumChars = SHRT_MAX
) const;

APTRA Advance ADE, C++ Class Reference 1-5


Common Utilities Classes
mString

UINT GetLength() const;

long AsInteger() const;


double AsReal() const;

BOOL IsInteger() const;


BOOL IsReal() const;

mString &operator=( const char *pChar );


mString &operator=( const mString &String );
mString &operator=( const long Integer );
mString &operator=( const double Real );
mString &operator=( const TCHAR Char );
mString &operator=( const char Char );
mString &operator+=( const mString &String );
mString &operator+=( const TCHAR *pString );
IMP_OR_EXP friend BOOL operator==( const mString &LeftStr,
const mString &RightStr
);
IMP_OR_EXP friend BOOL operator==( const mString &LeftStr,
const TCHAR *pRightStr
);
IMP_OR_EXP friend BOOL operator!=( const mString &LeftStr,
const mString &RightStr
);
IMP_OR_EXP friend BOOL operator!=( const mString &LeftStr,
const TCHAR *pRightStr
);
IMP_OR_EXP friend mString operator+( const mString &LeftStr,
const mString &RightStr
);
IMP_OR_EXP friend mString operator+( const mString &LeftStr,
const TCHAR *pRightStr
);
};

1-6 APTRA Advance ADE, C++ Class Reference


Common Utilities Classes
mString

CLASS DESCRIPTION
This class encapsulates a character string without a terminating character as an
array.
To optimise memory usage it shares strings rather than copying them. Memory
management is by reference counting.
It is used to pass string and File Ref literal Types to the Runtime Core Classes,
and data to and from Self Service devices. The class is designed to hide
character width from the user so as to allow user-created application code to
work unchanged with 8-bit or 16-bit character sets.

Data Type Usage in User-created Code


Where applicable, user-created code should always use the TCHAR interface
unless there is a specific requirement to use the char or WCHAR data type.

REQUIREMENTS
mcore.h, mcore.lib

SUPERCLASSES
None

CLASS METHODS

Constructors
Constructor — Default, page 1-9
Constructor — Wide Character Array, page 1-10
Constructor — Character Array (String), page 1-11
Constructor — Shallow Copy, page 1-12
Constructor — Integer, page 1-12
Constructor — Real, page 1-13
Constructor — Wide Character, page 1-13

APTRA Advance ADE, C++ Class Reference 1-7


Common Utilities Classes
mString

Constructor — Character, page 1-14


Constructor — multi-BYTE Array, page 1-15

Destructor
Destructor, page 1-16

Assignment Operators
Overloaded Assignment Operator — Copy, page 1-16
Overloaded Assignment Operator — Single Character/Wide Character, page
1-17
Overloaded Assignment Operator — Character Array (String), page 1-18
Overloaded Assignment Operator — Integer, page 1-18
Overloaded Assignment Operator — Real, page 1-19

Relational Operators
Overloaded Equality Operator — Character/Wide Character Array, page 1-20
Overloaded Inequality Operator — Character/Wide Character, page 1-21

Manipulation Operators and Methods


Concatenation Operator — Character/Wide Character, page 1-22
Overloaded Addition Operator — Character/Wide Character, page 1-23
InsertStr — Character/Wide Character, page 1-24
ReplaceStr, page 1-25
SubStr — Character/Wide Character, page 1-26

Export Methods
Export — Character/Wide Character, page 1-27
Export — Byte, page 1-28

1-8 APTRA Advance ADE, C++ Class Reference


Common Utilities Classes
mString

Retrieval Methods
FindStr — Character/Wide Character, page 1-29
Parse — Character/Wide Character, page 1-30

Information Methods
GetLength, page 1-31
IsInteger, page 1-32
IsReal, page 1-33

Conversion Methods
asInteger, page 1-34
asReal, page 1-35

Constructor — Default 1

USE
To create an mString object containing no data.

SYNOPSIS
mString();

DATA REFERENCES
NULL, page A-2

METHOD DESCRIPTION
This method initialises a new mString object with the character array initialised
to NULL.

APTRA Advance ADE, C++ Class Reference 1-9


Common Utilities Classes
mString

Constructor — Wide Character Array 1

USE
To create an mString object initialised with a wide character array.

SYNOPSIS
mString( const TCHAR *pChar,
const UINT Offset = 0,
const UINT Length = SHRT_MAX
);

PARAMETERS
pChar Pointer to the character string to be copied.
Offset The index of the start of the substring to be copied.
Length The number of characters to be copied; defaults to the
maximum possible value.

ERRORS
None

DATA REFERENCES
BYTE, page A-2
NULL, page A-2
TCHAR, page A-2

METHOD DESCRIPTION
This method initialises a new mString object with a wide character array.
The number of characters to be copied is given by Length, and the characters
are copied from position (pChar + Offset) in the string to which pChar points.
If pChar is NULL or the start location is beyond the end of the string, a null
character array is created.

1-10 APTRA Advance ADE, C++ Class Reference


Common Utilities Classes
mString

Constructor — Character Array (String) 1

USE
To create an mString object initialised with a character string.

SYNOPSIS
mString( const char *pChar,
const UINT Offset = 0,
const UINT Length = SHRT_MAX
);

PARAMETERS
pChar Pointer to the character string to be copied.
Offset The index of the start of the substring to be copied.
Length The number of characters to be copied; defaults to the
maximum possible value.

ERRORS
None

DATA REFERENCES
WCHAR, page A-2
NULL, page A-2

METHOD DESCRIPTION
This method initialises a new mString object with a substring of a character
string, that is, a null terminated character array. The length is given by the
parameter Length and copied from position (pChar + Offset), where the
parameter Offset is used as an offset to locate the start of the substring to be
copied.
If pChar is NULL or the start location is beyond the end of the string, a null
character array is created in the mString object.

APTRA Advance ADE, C++ Class Reference 1-11


Common Utilities Classes
mString

The character copy is terminated by the end of the character string, that is the
null character, even if the len value would go past the terminator.

Constructor — Shallow Copy 1

USE
To create an mString object that is a copy of another mString object.

SYNOPSIS
mString( const mString &String );

PARAMETERS
String Reference to the mString object to be copied.

METHOD DESCRIPTION
This method initialises a new mString object with a copy of the character array
in the mString object referenced by the parameter String. The contents of the
data array in the String object are not copied to the new mString object but are
shared between them.

Constructor — Integer 1

USE
To create an mString object that contains an integer converted to a character
array.

SYNOPSIS
mString( const long Integer );

1-12 APTRA Advance ADE, C++ Class Reference


Common Utilities Classes
mString

PARAMETERS
Integer The long integer to be converted to a character array and
used to initialise the mString object.

METHOD DESCRIPTION
This method initialises a new mString object with Integer converted to a
character array.

Constructor — Real 1

USE
To create an mString object that contains a real number converted to a character
array.

SYNOPSIS
mString( const double Real );

PARAMETERS
Real The double floating point to be converted to a character
array and used to initialise the mString object.

METHOD DESCRIPTION
This method initialises a new mString object with Real converted to a character
array. The number of significant digits allowed is 15; reals with more
significant digits will be rounded to 15.

Constructor — Wide Character 1

USE
To create an mString object that contains a single wide character of type
TCHAR.

APTRA Advance ADE, C++ Class Reference 1-13


Common Utilities Classes
mString

SYNOPSIS
mString( const TCHAR Char );

PARAMETERS
Char The wide character that is used to initialise the array.

ERRORS
None

DATA REFERENCES
BYTE, page A-2
TCHAR, page A-2

METHOD DESCRIPTION
This method creates a new mString object with an array of length 1 initialised
with the supplied wide character which is passed by value, not reference.

Constructor — Character 1

USE
To create an mString object that contains a single character of type char.

SYNOPSIS
mString( const char Char );

PARAMETERS
Char The character that is used to initialise the array.

ERRORS
None

1-14 APTRA Advance ADE, C++ Class Reference


Common Utilities Classes
mString

DATA REFERENCES
BYTE, page A-2

METHOD DESCRIPTION
This method creates a new mString object with an array of length 1 initialised
with the supplied character which is passed by value, not reference.

Constructor — multi-BYTE Array 1

USE
To create an mString object initialised with an array of multiple BYTE
characters.

SYNOPSIS
mString( const BYTE *pByte,
const UINT NumChars,
const UINT BytesPerChar
);

PARAMETERS
pByte Pointer to the multiple BYTE array to be copied.
NumChars The number of multiple BYTE characters to be copied.
BytesPerChar The size in BYTEs of a character.

ERRORS
None

DATA REFERENCES
BYTE, page A-2
NULL, page A-2

APTRA Advance ADE, C++ Class Reference 1-15


Common Utilities Classes
mString

METHOD DESCRIPTION
This method initialises a new mString object with a copy of the multiple BYTE
character array pointed to by pByte. NumChars is the length of the array in
multiple BYTE characters, the size of which, in BYTES, is defined by
BytesPerChar.

If pByte is NULL or BytesPerChar is zero, a null character array is created in


mString object.

Destructor 1

USE
To delete an mString object.

SYNOPSIS
~mString();

METHOD DESCRIPTION
This method deletes an mString object.

Overloaded Assignment Operator — Copy 1

USE
To copy one mString object to another.

SYNOPSIS
mString &operator=( const mString &String );

PARAMETERS
String Reference to the mString object to be copied.

1-16 APTRA Advance ADE, C++ Class Reference


Common Utilities Classes
mString

RETURN VALUE
A reference to the mString object to which the String value has been assigned.

METHOD DESCRIPTION
This operator overloads the assignment operator and assigns the String object
to the returned mString object. The contents of data array in the String object is
not copied to the new mString object but is shared between them.

Overloaded Assignment Operator — Single Character/Wide Character 1

USE
To assign a single character or wide character to an mString object.

SYNOPSES
mString &operator=( const char Char );

mString &operator=( const TCHAR Char );

PARAMETERS
Char The char or TCHAR character to be assigned to the
mString object.

RETURN VALUE
A reference to the mString object to which the character has been assigned.

METHOD DESCRIPTION
This operator overloads the assignment operator and assigns the single
character to the returned mString object.

APTRA Advance ADE, C++ Class Reference 1-17


Common Utilities Classes
mString

Overloaded Assignment Operator — Character Array (String) 1

USE
To assign a character string to an mString object.

SYNOPSIS
mString &operator=( const char *pChar );

PARAMETERS
pChar Pointer to the character string to be assigned.

RETURN VALUE
A reference to the mString object that has had the string value assigned to it.

ERRORS
None

DATA REFERENCES
NULL, page A-2

METHOD DESCRIPTION
This operator overloads the assignment operator and assigns a character string,
in the form of a null terminated character array, to the array of the returned
mString object.
If pChar is null no assignment occurs.

Overloaded Assignment Operator — Integer 1

USE
To assign an integer, converted to a string, to an mString object.

1-18 APTRA Advance ADE, C++ Class Reference


Common Utilities Classes
mString

SYNOPSIS
mString &operator=( const long Integer );

PARAMETERS
Integer The long integer to be converted.

RETURN VALUE
A reference to the mString object that has had the converted long integer
assigned to it.

METHOD DESCRIPTION
This operator overloads the assignment operator and assigns a long integer
Integer (which is converted to a string, that is a null terminated character
array) to the returned mString object.

Overloaded Assignment Operator — Real 1

USE
To assign a real, converted to a string, to an mString object.

SYNOPSIS
mString &operator=( const double Real );

PARAMETERS
Real The double precision floating point number to be
converted.

RETURN VALUE
A reference to the mString object that has had the converted real number
assigned to it.

APTRA Advance ADE, C++ Class Reference 1-19


Common Utilities Classes
mString

METHOD DESCRIPTION
This operator overloads the assignment operator and assigns a real number
converted to a string (that is, a null terminated character array) to the returned
mString object.
The conversion creates a string 20 characters long, with 15 significant digits. If
the number has a greater number of significant digits, these are rounded to 15.

Overloaded Equality Operator — Character/Wide Character Array 1

USE
To compare an mString object with another character or wide character
mString object for equality.

SYNOPSES
IMP_OR_EXP friend BOOL operator==( const mString &LeftStr,
const mString &RightStr
);

IMP_OR_EXP friend BOOL operator==( const mString &LeftStr,


const TCHAR *pRightStr
);

PARAMETERS
LeftStr Reference to the mString object on the left of the
operator.
RightStr Reference to the mString object on the right of the
operator.
pRightStr Pointer to the mString object on the right of the operator.

RETURN VALUE
An integer with the following possible values:
1 The mString objects are equivalent.

1-20 APTRA Advance ADE, C++ Class Reference


Common Utilities Classes
mString

0 The mString objects are not equivalent.

METHOD DESCRIPTION
This operator overloads the equality operator and compares the mString object
on the left side of the operator with that on the right. The operator returns 1 if
the LeftStr and RightStr are the same, otherwise 0.
Two criteria are compared to check for equivalence; the length of the mString
object’s character array, and the actual characters in the array. Both of these
tests must show equivalence for the return value to be 1.

Overloaded Inequality Operator — Character/Wide Character 1

USE
To compare two mString objects for inequality.

SYNOPSES
IMP_OR_EXP friend BOOL operator!=( const mString &LeftStr,
const mString &RightStr
);

IMP_OR_EXP friend BOOL operator!=( const mString &LeftStr,


const TCHAR *pRightStr
);

PARAMETERS
LeftStr Reference to the mString object on the left of the
operator.
RightStr Reference to the mString object on the right of the
operator.
pRightStr Pointer to the mString object on the right of the operator.

APTRA Advance ADE, C++ Class Reference 1-21


Common Utilities Classes
mString

RETURN VALUE
An integer with the following possible values:
1 The mString objects are not equivalent.
0 The mString objects are equivalent.

METHOD DESCRIPTION
This operator overloads the inequality operator and compares the mString
object on the left side of the operator with that on the right. The operator
returns 1 if the LeftStr and RightStr are not the same, otherwise 0.
Two things are tested to check for equivalence; the length of the mString
object’s character array, and the actual characters in the array. If one of the tests
shows inequality the return value is 1.

Concatenation Operator — Character/Wide Character 1

USE
To concatenate one mString object of character or wide character type onto the
end of another.

SYNOPSES
mString &operator+=( const mString &String );

mString &operator+=( const TCHAR *pString );

PARAMETERS
String Reference to the mString object that is concatenated.
pString Pointer to the mString object that is concatenated.

RETURN VALUE
A reference to the mString object that has had the String value concatenated to
the end of the mString object that was on the left of the operator.

1-22 APTRA Advance ADE, C++ Class Reference


Common Utilities Classes
mString

METHOD DESCRIPTION
This operator overloads the assignment operator and concatenates the String
object onto the end of the mString object that is referenced on the left of the
operator and returns this combined mString object.

Overloaded Addition Operator — Character/Wide Character 1

USE
To concatenate one mString object onto the end of another.

SYNOPSES
IMP_OR_EXP friend mString operator+( const mString &LeftStr,
const mString &RightStr
);

IMP_OR_EXP friend mString operator+( const mString &LeftStr,


const TCHAR *pRightStr
);

PARAMETERS
LeftStr Reference to the mString object on the left of the
operator.
RightStr Reference to the mString object on the right of the
operator.
pRightStr Pointer to the mString object on the right of the operator.

RETURN VALUE
A reference to the mString object that has had the RightStr mString object
value concatenated to the end of the LeftStr mString object.

APTRA Advance ADE, C++ Class Reference 1-23


Common Utilities Classes
mString

METHOD DESCRIPTION
This operator overloads the addition operator and concatenates the mString
object on the right side of the operator onto the end of the mString object on the
left and returns this combined mString object.

InsertStr — Character/Wide Character 1

USE
To insert a character array from another mString object into this mString object.

SYNOPSES
mString &InsertStr( const mString &String,
const UINT Offset = 0
);
mString &InsertStr( const TCHAR *pString,
const UINT Offset = 0
);

PARAMETERS
String Reference to the mString object whose array is to be
inserted.
pString Pointer to the mString object to be inserted.
Offset The index of the insertion point in this mString object’s
array. The first character is at index 0. The default value
is also 0.

RETURN VALUE
A reference to the mString object that has had the String value inserted in it.

METHOD DESCRIPTION
This method inserts String into this mString object. The Offset is the position
in this mString object’s character array from which the insertion is to start.

1-24 APTRA Advance ADE, C++ Class Reference


Common Utilities Classes
mString

If Offset is beyond the end of this mString object’s character array, the String is
concatenated onto the end of this mString object’s array.

ReplaceStr 1

USE
To replace an mString object in this mString object with another mString object.

SYNOPSIS
int ReplaceStr( const mString &SearchString,
const mString &ReplaceString,
const UINT Offset = 0 );

PARAMETERS
SearchString Reference to the mString object that is searched for and
replaced.
ReplaceString Reference to the mString object that is used as the
replacement.
Offset The index of the search point in this mString object. The
first character is at index 0. The default value is also 0.

RETURN VALUE
A reference to the mString object that has had the SearchString value replaced
with ReplaceString.

METHOD DESCRIPTION
This method searches this mString object for SearchString and if found
replaces it with ReplaceString. The Offset is the position in this mString
object’s character array that the search is to start from.
If Offset is beyond the end of this mString object’s character array, no
replacement occurs.

APTRA Advance ADE, C++ Class Reference 1-25


Common Utilities Classes
mString

SubStr — Character/Wide Character 1

USE
To copy part of the array of an mString object.

SYNOPSES
IMP_OR_EXP friend mString SubStr( const mString &String,
const UINT Offset = 0,
const UINT Length = SHRT_MAX
);

IMP_OR_EXP friend mString SubStr( const TCHAR *pString,


const UINT Offset = 0,
const UINT Length = SHRT_MAX
);

PARAMETERS
String Reference to the mString object, part of whose array is to
be copied.
pString Pointer to the mString object of which a part is to be
copied.
Offset The index, in String, of the start of the copy. The first
character is at index 0. The default value is also 0.
Length The number of characters to be copied. The default is the
maximum possible value.

RETURN VALUE
A reference to the mString object that is a copy of part of the String.

METHOD DESCRIPTION
This method copies and returns a part of String. The Offset is the position in
this mString object’s character array that the extraction is to start from. String is
not changed by the method.
If Offset is beyond the end of String’s character array, no extraction occurs.

1-26 APTRA Advance ADE, C++ Class Reference


Common Utilities Classes
mString

The character copy is terminated by the end of the mString object’s character
array, even if the Length value would go past this point.

Export — Character/Wide Character 1

USE
To export all or part of the character array of an mString object to a character
buffer as a NULL-terminated string.

SYNOPSES
char *Export( char *pBuffer,
const UINT Offset = 0,
const UINT NumChars = SHRT_MAX
) const;

WCHAR *Export( WCHAR *pBuffer,


const UINT Offset = 0,
const UINT NumChars = SHRT_MAX
) const;

PARAMETERS
pBuffer Pointer to the buffer to which the string is to be copied.
Offset The index in the array of the start of the copy. The first
character is at index 0. The default value is also 0.
NumChars The number of characters to be copied. The default is the
maximum possible value.

RETURN VALUE
A pointer to the buffer to which the character string is exported.

METHOD DESCRIPTION
This method copies all or part of the character array of an mString object as a
NULL-terminated string to a character buffer of type char or WCHAR. The

APTRA Advance ADE, C++ Class Reference 1-27


Common Utilities Classes
mString

Offset is the position in this mString object’s character array from which the
copy is to start.
If Offset is beyond the end of the character array, no copy occurs.
The character copy is terminated by the end of the mString object’s character
array, even if the NumChars value would go beyond this point.

Export — Byte 1

USE
To export all or part of the character array of an mString object to a BYTE
buffer.

SYNOPSIS
BYTE *Export( BYTE *pBuffer,
const UINT Offset = 0,
const UINT NumChars = SHRT_MAX
) const;

PARAMETERS
pBuffer Pointer to the buffer to which the string is to be copied.
Offset The index in the array of the start of the copy. The first
character is at index 0. The default value is also 0.
NumChars The number of characters to be copied. The default is the
maximum possible value.

RETURN VALUE
A pointer to the buffer to which the character string is exported.

METHOD DESCRIPTION
This method copies all or part of the character array of an mString object to a
buffer of type BYTE. The Offset is the position in this mString object’s character
array from which the copy is to start.

1-28 APTRA Advance ADE, C++ Class Reference


Common Utilities Classes
mString

If Offset is beyond the end of the character array, no copy occurs.


The character copy is terminated by the end of the mString object’s character
array, even if the NumChars value would go beyond this point.

FindStr — Character/Wide Character 1

USE
To find if one mString is in another.

SYNOPSES
IMP_OR_EXP friend int FindStr( const mString &StringToBeSearched,
const mString &SearchString,
const UINT Offset = 0 );

IMP_OR_EXP friend int FindStr( const mString &StringToBeSearched,


const TCHAR *pSearchString,
const UINT Offset = 0 );

PARAMETERS
StringToBeSearched Reference to the mString object that is searched.
SearchString Reference to the mString object that is searched for.
pSearchString Pointer to the mString object that is searched for.
Offset The index of the search start point in
StringToBeSearched. The first character is at index 0. The
default value is also 0.

RETURN VALUE
An integer with the following possible values:
>= 0 This returns an integer that is the index of the array
position of SearchString in StringToBeSearched.
-1 The search has failed.

APTRA Advance ADE, C++ Class Reference 1-29


Common Utilities Classes
mString

METHOD DESCRIPTION
This method searches StringToBeSearched for SearchString. The Offset is the
position in the character array of StringToBeSearched from which the search is
to start. If SearchString is found, its position in StringToBeSearched is
returned.
If Offset is beyond the end of StringToBeSearched, or SearchString is not
found in StringToBeSearched, or either of the mString objects is null, the search
fails and a value of -1 is returned.

Parse — Character/Wide Character 1

USE
To divide an mString object into sections before and after a given delimiter.

SYNOPSES
IMP_OR_EXP friend mString Parse( mString &String,
const mString &Delimiter
);

IMP_OR_EXP friend mString Parse( mString &String,


const TCHAR *pDelimiter
);

PARAMETERS
String Reference to the mString object that is parsed. The initial
value is changed to the part of the mString object after
the delimiter.
Delimiter Reference to the delimiter that is used to separate
sections of the mString object.
pDelimiter Pointer to the delimiter that is used to separate sections
of the mString object.

1-30 APTRA Advance ADE, C++ Class Reference


Common Utilities Classes
mString

RETURN VALUE
This returns the section of mString object found before Delimiter.

DATA REFERENCES
TCHAR, page A-2

METHOD DESCRIPTION
This method searches String for Delimiter. It splits the String into the section
before the delimiter (which is returned) and the mString object after the
delimiter (which is returned as String).
If the delimiter is not found in the mString object, all of String is returned. If
this occurs, since all of String has been parsed, it is returned as a null mString
object.
Multiple calls to this method can be used to split a delimited mString object
into many tokens.

GetLength 1

USE
To find the length of the mString object’s character array.

SYNOPSIS
UINT GetLength() const;

RETURN VALUE
The length of the character array as an integer.

METHOD DESCRIPTION
See USE above.

APTRA Advance ADE, C++ Class Reference 1-31


Common Utilities Classes
mString

IsInteger 1

USE
To check whether the contents of the mString object’s character array can be
converted to an integer.

SYNOPSIS
BOOL IsInteger() const;

RETURN VALUE
An unsigned integer with the following possible values:
1 The mString object can be converted to an integer.
0 The mString object cannot be converted to an integer.

SEE ALSO
asInteger, page 1-34

METHOD DESCRIPTION
This method checks that the mString object contains a character array with the
following format:
[whitespace][sign]digits[whitespace]
where the sections in brackets are optional. The sign is optional but if it exists it
must be directly before the digits. The digits can be any numeric characters that
form an integer value.
If the whole mString object conforms to this format, 1 is returned, otherwise 0 is
returned.

1-32 APTRA Advance ADE, C++ Class Reference


Common Utilities Classes
mString

IsReal 1

USE
To check whether the mString object’s character array can be converted to a real
number.

SYNOPSIS
BOOL IsReal() const;

RETURN VALUE
An unsigned integer with the following possible values:
1 The mString object can be converted to a real.
0 The mString object cannot be converted.

SEE ALSO
asReal, page 1-35

METHOD DESCRIPTION
This method checks that the mString object contains a character array with the
following format:
[whitespace][sign]digits[.digits[exponent[sign]digits]][whitespace]
where the sections in brackets are optional. The sign, decimal point, exponent
and sign of exponent are all optional but if they exist they must be directly
beside the next part of the format. The digits can be any numeric characters that
form an integer value.
If the whole mString object conforms to this format, 1 is returned, otherwise 0 is
returned.

APTRA Advance ADE, C++ Class Reference 1-33


Common Utilities Classes
mString

asInteger 1

USE
To get this mString object’s character array converted to a integer.

SYNOPSIS
long AsInteger() const;

RETURN VALUE
A long integer which is the converted value of this mString object’s character
array.

ERRORS
None

SEE ALSO
IsInteger, page 1-32

METHOD DESCRIPTION
This method converts this mString object’s character array and returns a long
integer.
It checks that the mString object contains a character array with the following
format:
[whitespace][sign]digits[whitespace]
where the sections in brackets are optional. The sign is optional but if it exists it
must be directly before the digits. The digits can be any numeric characters that
form an integer value.
If the whole mString object conforms to this format the type conversion is done
and an integer value is returned. If the type conversion fails, 0 is returned.
Because a type conversion failure returning 0, and the value of the integer
returned being 0, cannot be distinguished, the type conversion should be tested

1-34 APTRA Advance ADE, C++ Class Reference


Common Utilities Classes
mString

using the IsInteger method, page 1-32, before attempting to execute this
method.

asReal 1

USE
To obtain the mString object’s character array converted to a real number.

SYNOPSIS
double AsReal() const;

RETURN VALUE
The value of the mString object’s character array as a double floating point
number.

ERRORS
None

SEE ALSO
IsReal, page 1-33

METHOD DESCRIPTION
This method converts this mString object’s character array and returns a double
floating point value.
It checks that the mString object contains a character array with the following
format:
[whitespace][sign]digits[.digits[exponent[sign]digits]][whitespace]
where the sections in brackets are optional.
The sign, decimal point, exponent and the sign of the exponent are all optional
but if they exist they must be directly next to the neighbouring element of the
format with no white space between them.

APTRA Advance ADE, C++ Class Reference 1-35


Common Utilities Classes
mString

The digits can be any numeric characters that form an integer value.
If the whole mString object conforms to this format the conversion is done and
an integer value is returned. If the conversion fails, 0.0 is returned.
The IsReal method should be used before the type conversion is attempted in
order to check whether the conversion will succeed, since it is not possible to
distinguish between a conversion failure and the value of the integer returned
being 0.0.

1-36 APTRA Advance ADE, C++ Class Reference


Table of Contents
Runtime Core Classes

Chapter 2
Runtime Core Classes

Overview 2-1

mConcreteWorker (abstract) 2-2

mDoer (abstract) 2-4

mEventContext (abstract) 2-12

mGetter (abstract) 2-19

mHandle 2-23

mHandleGetter (abstract) 2-30

mHandlePutter (abstract) 2-33

mIntegerGetter (abstract) 2-36

mIntegerPutter (abstract) 2-39

APTRA Advance ADE, C++ Class Reference


Table of Contents
Runtime Core Classes

mPutter (abstract) 2-43

mRealGetter (abstract) 2-47

mRealPutter (abstract) 2-50

mSignal 2-53

mSignaller (abstract) 2-61

mStringGetter (abstract) 2-62

mStringPutter (abstract) 2-66

mTBasicWorkGroup (template) 2-69

mTDoerWorkGroup (template) 2-73

mUserEvent 2-83

mWorkContext 2-87

mWorkGroup (abstract) 2-96


Runtime Core Classes
2

Overview

Overview 2

This chapter contains class descriptions for the published core classes in
Advance ADE.

APTRA Advance ADE, C++ Class Reference 2-1


Runtime Core Classes
mConcreteWorker (abstract)

mConcreteWorker (abstract) 2

USE
Abstract base class for all concrete Worker Classes.

CLASS DECLARATION
class mConcreteWorker
{
protected:
mConcreteWorker() ;
public:
void SetId( char* aComponentID );
char* GetId();
};

CLASS DESCRIPTION
This abstract base class is used as the Superclass for all concrete Worker
Classes.
The ComponentID parameter is a pointer to a unique object identifier which is
used to identify every object in an entire Advance ADE software system. It
uniquely identifies Workers even across applications. An example of the use of
the Component ID across applications is the use of the Shared Store Worker.
This Worker by default uses the Component ID to name shared memory. If the
same Shared Store Worker is shared between two applications, in both of these
applications the Shared Worker will have the same Component ID and thus
will refer to the same shared memory.

REQUIREMENTS
mcore.h, mcore.lib

SUPERCLASSES
None

2-2 APTRA Advance ADE, C++ Class Reference


Runtime Core Classes
mConcreteWorker (abstract)

CLASS METHODS
SetId, page 2-3
GetId, page 2-3

SetId 2

USE
To set the Worker’s Component ID.

SYNOPSIS
void SetId( char* aComponentID );

PARAMETERS
aComponentID Pointer to a variable length character string containing
the Worker’s Component ID.

METHOD DESCRIPTION
The SetId method is called with a pointer to the Worker’s Component ID when
a Worker is created.

GetId 2

USE
To query the Worker’s Component ID.

SYNOPSIS
char* GetId();

METHOD DESCRIPTION
See USE above.

APTRA Advance ADE, C++ Class Reference 2-3


Runtime Core Classes
mDoer (abstract)

mDoer (abstract) 2

USE
Base class for all Doer Worker Classes.

CLASS DECLARATION
class IMP_OR_EXP mDoer : public mSignaller
{
protected:
mDoer();

public:
virtual ~mDoer();
virtual void Start( mEventContext* aEventContext,
mWorkContext& aExecutingContext,
mWorkContext* aForwardContext
) = 0;
virtual mSignal* Stop( mEventContext* aEventContext,
mWorkContext& aWorKContext
) = 0;
virtual mSignal* ProcessEvent(mEventContext* aEventContext,
mWorkContext& aWorkContext,
const mEvent* aEvent
) = 0;
virtual mSignal* EventDefault(mEventContext* aEventContext,
const mWorkContext& aWorkConte
xt, const mEvent* aEvent
) const;
};

CLASS DESCRIPTION
This class is the base class for all Doer Worker Classes; that is, Worker Classes
that can be activated and deactivated and that process Events. It is a subclass of
mSignaller (abstract).

2-4 APTRA Advance ADE, C++ Class Reference


Runtime Core Classes
mDoer (abstract)

SEE ALSO
mEventContext (abstract), page 2-12
mSignal, page 2-53
mSignaller (abstract), page 2-61
mWorkContext, page 2-87

REQUIREMENTS
mcore.h, mcore.lib

SUPERCLASSES
mSignaller (abstract), page 2-61

INHERITED METHODS
None

CLASS METHODS
EventDefault, page 2-5
ProcessEvent (deferred), page 2-7
Start (deferred), page 2-8
Stop (deferred), page 2-10

EventDefault 2

USE
An event handler for unrecognised mEvents.

SYNOPSIS
virtual mSignal* EventDefault( mEventContext* aEventContext,
const mWorkContext& aWorkContext,
const mEvent* aEvent ) const;

APTRA Advance ADE, C++ Class Reference 2-5


Runtime Core Classes
mDoer (abstract)

PARAMETERS
aEventContext Pointer to the mEventContext object which is to be used
to get and post mEvents.
aWorkContext Reference to the mWorkContext which has a list of the
mWorkGroups that have been activated in order to get
to this Worker.
aEvent Pointer to the mEvent to be processed.

RETURN VALUE
Pointer to an mSignal object, which should be used as the return value for the
ProcessEvent method.

ERRORS
None

CLASS REFERENCES
mEvent (abstract), page 1-2
mEventContext (abstract), page 2-12
mSignal, page 2-53
mWorkContext, page 2-87

METHOD DESCRIPTION
This method should be executed by an active Doer Worker when the mEvent it
has received through the ProcessEvent method is not recognised as one it can
process. It should be called with the parameters that were passed to the
ProcessEvent method.
This method is designed to handle internal control Events that are reserved by
NCR and should not be redefined in any user-created class.

2-6 APTRA Advance ADE, C++ Class Reference


Runtime Core Classes
mDoer (abstract)

ProcessEvent (deferred) 2

USE
To give an Event to the Doer Worker.

SYNOPSIS
virtual mSignal* ProcessEvent( mEventContext* aEventContext,
mWorkContext& aWorkContext,
const mEvent* aEvent ) = 0;

PARAMETERS
aEventContext Pointer to the mEventContext which is to be used to get
and post mEvents.
aWorkContext Reference to the mWorkContext which has a list of the
mWorkGroups that the mEvent has passed through to
get to this Worker.
aEvent Pointer to the mEvent that is processed.

RETURN VALUE
A pointer to an mSignal, or a NULL pointer if no mSignal is generated.

ERRORS
None

DATA REFERENCES
NULL, page A-2

CLASS REFERENCES
mEvent (abstract), page 1-2
mEventContext (abstract), page 2-12
mSignal, page 2-53
mWorkContext, page 2-87

APTRA Advance ADE, C++ Class Reference 2-7


Runtime Core Classes
mDoer (abstract)

METHOD DESCRIPTION
This method is executed to pass an mEvent to an active Doer Worker. If the
Doer recognises the mEvent it processes it and, when finished, may return an
mSignal. If the Doer is a Coordinator it may pass the Event on to all of its active
Subworkers.
Its first two parameters are used to define its activation context. In normal
usage only the first of these two, aEventContext is actually used. The third
parameter is a pointer to the mEvent that it has to process.
The aEventContext parameter is a pointer to the mEventContext which is to be
used to post and get mEvents.
The aWorkContext parameter is a reference to an mWorkContext (which is the
hierarchical list of the mWorkGroups through which the mEvent had to go to
get to this Worker). This is only used by specific Coordinators which pass it on
to their active Work Groups and return any Signals produced by their
Subworkers.
The method returns a pointer to an mSignal generated by the processing of the
mEvent. If the Doer does not generate an mSignal for this mEvent, the pointer
is null.
If the Worker along with its possible Subworkers can produce more than one
mSignal, Signal Priority can be used to choose between them. If there are two
mSignals with the same Priority another methodology has to be imposed to
separate them; it is typically done using the position of the Worker in the Work
Group (the first Worker in the Work Group has the highest Priority, the last has
the lowest). This is the typical way of deciding Priority, but other methods can
be used.
This deferred method must be implemented in a subclass.

Start (deferred) 2

USE
To activate the Doer Worker.

2-8 APTRA Advance ADE, C++ Class Reference


Runtime Core Classes
mDoer (abstract)

SYNOPSIS
virtual void Start( mEventContext* aEventContext,
mWorkContext& aExecutingContext,
mWorkContext* aForwardContext
) = 0;

PARAMETERS
aEventContext Pointer to the mEventContext which is to be used to get
and post mEvents.
aExecutingContext Reference to the mWorkContext which has a list of the
Work Groups that have been activated in order to get to
this Worker. This value can be null.
aForwardContext Reserved by NCR.

ERRORS
None

CLASS REFERENCES
mEventContext (abstract), page 2-12
mWorkContext, page 2-87

METHOD DESCRIPTION
This method is executed to activate the Worker. If the Doer is a Coordinator it
could activate all of its Subworkers.
Its parameters are used to define its activation context. In normal usage only
the first of these, aEventContext is actually used.
The aEventContext parameter is a pointer to the mEventContext which is to be
used to post and get mEvents.
The aExecutingContext parameter is a reference to an mWorkContext (which is
the hierarchical list of the mWorkGroups which have had to be activated to get
to this Worker). This is only used by specific Coordinators and should be
ignored and simply passed on to any Subworkers that are to be activated.

APTRA Advance ADE, C++ Class Reference 2-9


Runtime Core Classes
mDoer (abstract)

The aForwardContext parameter is reserved by NCR.


This deferred method must be implemented in a subclass.

Stop (deferred) 2

USE
To deactivate the Doer Worker.

SYNOPSIS
virtual mSignal* Stop( mEventContext* aEventContext,
mWorkContext& aWorKContext
) = 0;

PARAMETERS
aEventContext Pointer to the mEventContext which is to be used to get
and post mEvents.
aWorkContext Reference to the mWorkContext which has a list of the
Work Groups that have been deactivated in order to get
to this Worker.

RETURN VALUE
A pointer to a late mSignal, or a NULL pointer if no mSignal is generated.

ERRORS
None

DATA REFERENCES
NULL, page A-2

CLASS REFERENCES
mEventContext (abstract), page 2-12
mWorkContext, page 2-87

2-10 APTRA Advance ADE, C++ Class Reference


Runtime Core Classes
mDoer (abstract)

mSignal, page 2-53

METHOD DESCRIPTION
This method is executed to deactivate the Worker. If the Doer is a Coordinator
it should deactivate all of its active Subworkers.
Its parameters are used to define its activation context. In normal usage only
the first of these two, aEventContext is actually used.
The aEventContext parameter is a pointer to the mEventContext which is to be
used to post and get mEvents.
The aWorkContext parameter is a reference to an mWorkContext (which is the
hierarchical list of the mWorkGroups through which the message to deactivate
had to go to get to this Worker). This is only used by specific Coordinators
which pass it on to their Work Groups that are to be deactivated and return any
late Signals produced by their Subworkers. The Coordinators are deactivated
after their Subworkers.
This method is responsible for checking whether there are any mUserEvents on
the Event Queue (using the supplied mEventContext), which are intended for
this Worker. If any are found they are removed from the Event Queue and
processed. If the processing of this mUserEvent causes the Worker to generate
an mSignal, a pointer to this is returned, otherwise a NULL pointer is returned.
This type of mSignal is referred to as “late” since the processing of it is done as
the Worker is deactivating.
If the Worker along with its possible Subworkers can produce more than one
late mSignal, Signal Priority can be used to choose between them. If there are
two late mSignals with the same Priority another methodology has to be
imposed to separate them; it is typically done using the position of the Worker
in the Work Group (the first Worker in the Work Group has the highest
Priority, the last has the lowest). This is the typical prioritisation method but
other methods can be used.
This deferred method must be implemented in a subclass.

APTRA Advance ADE, C++ Class Reference 2-11


Runtime Core Classes
mEventContext (abstract)

mEventContext (abstract) 2

USE
To post Events to and get late User Events from the Event Queue.

CLASS DECLARATION
class IMP_OR_EXP mEventContext
{
public:
virtual ~mEventContext(void ); // Destructor

virtual mUserEvent* GetUserEvent(mConcreteWorker* Source ) = 0;


virtual void PostEvent( mEvent* aEvnt ) = 0;
virtual mEventContext* GetParentEventContext(void ) const;
virtual void DisposeEvent(mEvent* theEvnt ) = 0;

protected:
mEventContext( mEventContext* ParentContext = NULL );
// constructor

};

CLASS DESCRIPTION
This class is the base class for all mEventContext classes including those which
are reserved by NCR.
The class constructor requires a pointer to the parent mEventContext of the
current thread, if there is one. This supports the construction of a hierarchy of
mEventContexts within one thread.

The PostEvent method puts an Event on the Event Queue. Events appear on the
queue from many sources. The GetUserEvent method takes an mUserEvent off
the Event Queue. The DisposeEvent method is used to delete mUserEvents that
have been retrieved from the Event Queue.

2-12 APTRA Advance ADE, C++ Class Reference


Runtime Core Classes
mEventContext (abstract)

These deferred methods are implemented in subclasses to handle different


internal Events, in particular User Events, generated by the Advance ADE
Worker. The queue structure is a First In First Out (FIFO) queue.

SEE ALSO
mEvent (abstract), page 1-2
mUserEvent, page 2-83

REQUIREMENTS
mcore.h, mcore.lib

SUPERCLASSES
None

CLASS METHODS
Constructor, page 2-13
DisposeEvent (deferred), page 2-14
GetUserEvent (deferred), page 2-16
PostEvent (deferred), page 2-17

Constructor 2

USE
To initialise a new mEventContext.

SYNOPSIS
mEventContext( mEventContext* ParentContext = NULL );
// constructor

APTRA Advance ADE, C++ Class Reference 2-13


Runtime Core Classes
mEventContext (abstract)

PARAMETERS
ParentContext Pointer to this mEventContext’s parent. The default
value is 0.

METHOD DESCRIPTION
This constructor sets up a new mEventContext object. The Parent Context
pointer argument is used to set up this object’s position in the hierarchy of
Context Events for a particular execution thread. If the argument is 0, the
default, this is the first mEventContext in the hierarchy.

DisposeEvent (deferred) 2

USE
To delete an mUserEvent that has been retrieved from the Event Queue using
the GetUserEvent method.

SYNOPSIS
virtual void DisposeEvent( mEvent* theEvnt ) = 0;

PARAMETERS
theEvnt Pointer to the mUserEvent to be deleted.

ERRORS
None

DATA REFERENCES
NULL, page A-2

CLASS REFERENCES
mEvent (abstract), page 1-2

2-14 APTRA Advance ADE, C++ Class Reference


Runtime Core Classes
mEventContext (abstract)

METHOD DESCRIPTION
This method should delete the mUserEvent in whatever manner is appropriate
for the mUserEvent type.
If the mUserEvent pointer is NULL the method should return without
executing or failing.

GetParentEventContext 2

USE
To get the parent Event Context of the current thread.

SYNOPSIS
virtual mEventContext* GetParentEventContext( void ) const;

RETURN VALUE
Pointer to the parent mEventContext object of the current thread. If the current
thread is at the top of the hierarchy of Event Contexts the pointer should be
NULL.

ERRORS
None

DATA REFERENCES
NULL, page A-2

CLASS REFERENCES
mUserEvent, page 2-83

METHOD DESCRIPTION
See USE above.
This accessor method must not modify the Parent Event Context.

APTRA Advance ADE, C++ Class Reference 2-15


Runtime Core Classes
mEventContext (abstract)

GetUserEvent (deferred) 2

USE
To get an mUserEvent from the mEventContext’s Event Queue.

SYNOPSIS
virtual mUserEvent* GetUserEvent( mConcreteWorker* Source ) = 0;

PARAMETERS
Source Pointer to the object that originated the mUserEvent.

RETURN VALUE
A pointer to an mUserEvent object taken from the Event Queue. This can be a
NULL pointer if no mUserEvent is available.

ERRORS
None

DATA REFERENCES
NULL, page A-2

CLASS REFERENCES
mUserEvent, page 2-83

METHOD DESCRIPTION
This method returns the next mUserEvent which was generated by the Worker
pointed to by the Source parameter. The mUserEvent is removed from the
Event Queue. If there is no mUserEvent available a NULL pointer is returned.
It also allows the Worker to handle late mUserEvents by allowing the Worker
to check the Event Queue for mUserEvents while it is deactivating, generating
a late mSignal if one is found. For more information about late mUserEvents,
see the mDoer (abstract) class method Stop.

2-16 APTRA Advance ADE, C++ Class Reference


Runtime Core Classes
mEventContext (abstract)

It is the responsibility of the caller of this method to dispose of the mUserEvent,


using the DisposeEvent method defined in this class.

PostEvent (deferred) 2

USE
To post an mEvent to the mEventContext’s Event Queue.

SYNOPSIS
virtual void PostEvent( mEvent* aEvnt ) = 0;

PARAMETERS
aEvnt Pointer to the mEvent to be queued.

ERRORS
None

CLASS REFERENCES
mEvent (abstract), page 1-2

METHOD DESCRIPTION
This method posts an mEvent onto the Event Queue.
This is normally used to allow the Worker to support the event driven structure
of the system, and currently handles User Events only.
For example, when some Doer Workers are activated they create a thread to
carry out a particular task. To avoid holding up other processes by waiting
until the thread is finished, the Doer sends itself an mEvent from within the
subthread and returns to its caller.
When the Doer Worker’s ProcessEvent method is next called it processes the
mEvent that the Worker posted to itself. The processing of the mEvent causes
the Worker to check the state of the thread it initiated when it was activated,
generating an mSignal if required.

APTRA Advance ADE, C++ Class Reference 2-17


Runtime Core Classes
mEventContext (abstract)

This deferred method must be implemented in a subclass.

2-18 APTRA Advance ADE, C++ Class Reference


Runtime Core Classes
mGetter (abstract)

mGetter (abstract) 2

USE
To define which Workers can return data.

CLASS DECLARATION
class mGetter
{
protected:
mGetter();
public:
virtual mHandle GetHandle() = 0;
virtual long GetInteger() = 0;
virtual double GetReal() = 0;
virtual mString GetString() = 0;
};

CLASS DESCRIPTION
This abstract class is the Superclass of all Workers that are termed Getters, that
is, Workers that can return data.
The public methods return the data types implied by their names. This can
mean data conversion since the same data can be returned as any one of the
supported data types. Data conversion errors can occur if invalid data
conversions are attempted.
All the public methods must be implemented in a subclass.

SEE ALSO
mHandle, page 2-23
mPutter (abstract), page 2-43
mString, page 1-4

APTRA Advance ADE, C++ Class Reference 2-19


Runtime Core Classes
mGetter (abstract)

REQUIREMENTS
mcore.h, mcore.lib

SUPERCLASSES
None

CLASS METHODS
GetHandle (deferred), page 2-20
GetInteger (deferred), page 2-21
GetReal (deferred), page 2-21
GetString (deferred), page 2-22

GetHandle (deferred) 2

USE
To get an mHandle object.

SYNOPSIS
virtual mHandle GetHandle() = 0;

RETURN VALUE
An mHandle object.

ERRORS
None

CLASS REFERENCES
mHandle, page 2-23

METHOD DESCRIPTION
This method returns an mHandle object. It must be implemented in a subclass.

2-20 APTRA Advance ADE, C++ Class Reference


Runtime Core Classes
mGetter (abstract)

GetInteger (deferred) 2

USE
To get an integer.

SYNOPSIS
virtual long GetInteger() = 0;

RETURN VALUE
A long integer.

METHOD DESCRIPTION
This method returns a long integer.
This deferred method must be implemented in a subclass.

GetReal (deferred) 2

USE
To get a real number.

SYNOPSIS
virtual double GetReal() = 0;

RETURN VALUE
A double floating point number.

METHOD DESCRIPTION
This method returns a double floating point number.
This deferred method must be implemented in a subclass.

APTRA Advance ADE, C++ Class Reference 2-21


Runtime Core Classes
mGetter (abstract)

GetString (deferred) 2

USE
To get an mString object.

SYNOPSIS
virtual mString GetString() = 0;

RETURN VALUE
An mString object.

ERRORS
None

CLASS REFERENCES
mString, page 1-4

METHOD DESCRIPTION
This method returns an mString object.
This deferred method must be implemented in a subclass.

2-22 APTRA Advance ADE, C++ Class Reference


Runtime Core Classes
mHandle

mHandle 2

USE
For storage and type checking of external data types.

CLASS DECLARATION
class mHandle
{
public:
mHandle();
mHandle( const mString& HandleID,
void* data
);
mHandle( const mHandle& copy );
mString GetID( void );
void* GetData( const mString& HandleID );
void PutData( const mString& HandleID,
void* data
);
void* GetData( void );
void PutData( void* data );
};

CLASS DESCRIPTION
The mHandle class provides storage and type checking for external data types.
The storage is implemented using a void pointer, thus enabling it to handle any
types of data. The GetData and PutData routines are used to save and retrieve
the pointer to the external data type with or without an associated Handle ID
(this is an identifier mString representing the external data types, used to
support type checking). The method GetID returns the identifier mString.
The default constructor method is not explained since it simply creates an
empty mHandle object.

APTRA Advance ADE, C++ Class Reference 2-23


Runtime Core Classes
mHandle

SEE ALSO
mString, page 1-4

REQUIREMENTS
mcore.h, mcore.lib

SUPERCLASSES
None

CLASS METHODS
Constructor — Default, page 2-24
Constructor — Copy, page 2-25
GetData — Type-checking, page 2-26
GetData — non Type-checking, page 2-27
GetID, page 2-27
PutData — Type-checking, page 2-28
PutData — non Type-checking, page 2-29

Constructor — Default 2

USE
To create an mHandle object containing a pointer to an external data type.

SYNOPSIS
mHandle( const mString& HandleID,
void* data );

PARAMETERS
HandleID Reference to the mHandle identifier mString.

2-24 APTRA Advance ADE, C++ Class Reference


Runtime Core Classes
mHandle

data Pointer to the external data. This pointer is stored by the


object.

CLASS REFERENCES
mString, page 1-4

METHOD DESCRIPTION
This constructor sets up an mHandle object with a pointer to an external data
type and an mString which is the Handle ID. The parameters data and HandleID
are both stored. There is no restriction on the data type and the HandleID is used
later for type checking.

Constructor — Copy 2

USE
To create an mHandle object using the data from an existing mHandle object.

SYNOPSIS
mHandle( const mHandle& copy );

PARAMETERS
copy Reference to the existing mHandle object of which the
new mHandle object will be a copy.

METHOD DESCRIPTION
This constructor instantiates a copy of an existing mHandle object. The external
data pointer and the Handle ID of the old mHandle object are copied to the
new.
The original mHandle is unchanged.

APTRA Advance ADE, C++ Class Reference 2-25


Runtime Core Classes
mHandle

GetData — Type-checking 2

USE
To return the external data, if it is of a given type.

SYNOPSIS
void* GetData( const mString& HandleID );

PARAMETERS
HandleID Reference to the mHandle identifier to be tested against
this object’s data type identifier.

RETURN VALUE
Pointer to the external data store. This pointer is NULL if an error has occurred.

ERRORS
Invalid Data Conversion, page B-2.

DATA REFERENCES
NULL, page A-2

CLASS REFERENCES
mString, page 1-4

METHOD DESCRIPTION
This method returns a pointer to an external data type store if it is of the correct
type. The type checking is done by comparing the supplied parameter HandleID
with the Handle identifier stored in the mHandle object.
If the supplied external data type identifier HandleID is not the same as the
stored identifier an error occurs and the returned pointer is null.

2-26 APTRA Advance ADE, C++ Class Reference


Runtime Core Classes
mHandle

GetData — non Type-checking 2

USE
To return the external data.

SYNOPSIS
void* GetData( void );

RETURN VALUE
Pointer to the external data store.

METHOD DESCRIPTION
This method returns a pointer to an external data type store without any type
checking.

GetID 2

USE
To return the external data type identifier.

SYNOPSIS
mString GetID( void );

RETURN VALUE
The mString that is used to represent the mHandle data type identifier.

ERRORS
None

CLASS REFERENCES
mString, page 1-4

APTRA Advance ADE, C++ Class Reference 2-27


Runtime Core Classes
mHandle

METHOD DESCRIPTION
This method returns an mString that is the Handle ID.

PutData — Type-checking 2

USE
To supply the mHandle object with external data of a given type.

SYNOPSIS
void PutData( const mString& HandleID,
void* data );

PARAMETERS
HandleID Reference to the mHandle identifier to be tested against
this object’s own data type identifier or stored if the
object does not have one.
data Pointer to the external data that is stored.

ERRORS
Invalid Data Conversion, page B-2.

CLASS REFERENCES
mString, page 1-4

METHOD DESCRIPTION
This method assigns the external data pointer, pointed to by the data
parameter, to the mHandle object (if the supplied external type identifier
HandleID is of the correct type). The type is checked by comparing the supplied
parameter HandleID to the Handle identifier stored in the mHandle object.
If the supplied external data type identifier HandleID is not the same as the
stored identifier, an error occurs. If the mHandle object does not have a stored

2-28 APTRA Advance ADE, C++ Class Reference


Runtime Core Classes
mHandle

identifier the one supplied as the HandleID parameter is stored and used as the
object’s identifier.

PutData — non Type-checking 2

USE
To supply the mHandle object with external data.

SYNOPSIS
void PutData( void* data );

PARAMETERS
data Pointer to the external data that is stored.

METHOD DESCRIPTION
This method assigns the supplied external data pointer to the mHandle object.
No type checking is carried out.

APTRA Advance ADE, C++ Class Reference 2-29


Runtime Core Classes
mHandleGetter (abstract)

mHandleGetter (abstract) 2

USE
Base class for Workers which can return an mHandle object.

CLASS DECLARATION
class mHandleGetter : public mGetter
{
protected:
mHandleGetter();
public:
virtual long GetInteger();
virtual double GetReal();
virtual mString GetString();
virtual mHandle GetHandle() = 0;
};

CLASS DESCRIPTION
This abstract class is the Superclass of Workers that can return an mHandle
object.
All Worker Classes for which data of a user defined type can be returned must
be subclasses of this class.

SEE ALSO
mHandle, page 2-23
mHandlePutter (abstract), page 2-33

REQUIREMENTS
mcore.h, mcore.lib

SUPERCLASSES
mGetter (abstract), page 2-19

2-30 APTRA Advance ADE, C++ Class Reference


Runtime Core Classes
mHandleGetter (abstract)

INHERITED METHODS
GetHandle (deferred) : mGetter (abstract), page 2-20
GetInteger (deferred) : mGetter (abstract), page 2-21
GetReal (deferred) : mGetter (abstract), page 2-21
GetString (deferred) : mGetter (abstract), page 2-22

CLASS METHODS
GetHandle (redeclared, deferred), page 2-31
Getinteger, GetReal, GetString, page 2-31

GetHandle (redeclared, deferred) 2

METHOD DESCRIPTION
This inherited method is redeclared in this class and must be implemented in a
subclass.

Getinteger, GetReal, GetString 2

USE
To block data conversion between Advance ADE Data Types and external data
types.

SYNOPSES
virtual long GetInteger();

virtual double GetReal();

virtual mString GetString();

APTRA Advance ADE, C++ Class Reference 2-31


Runtime Core Classes
mHandleGetter (abstract)

ERRORS
Invalid Data Conversion, page B-2.

CLASS REFERENCES
mString, page 1-4

METHOD DESCRIPTION
These inherited deferred methods are implemented in this class.
When any of these methods is called, an invalid data conversion error is
generated and a zero value is returned; GetInteger returns 0, GetReal 0.0 and
GetString an empty mString object.
This data conversion blocking is designed to stop external data types being
converted to Advance ADE Data Types.

2-32 APTRA Advance ADE, C++ Class Reference


Runtime Core Classes
mHandlePutter (abstract)

mHandlePutter (abstract) 2

USE
Base class for Workers which can accept mHandle objects.

CLASS DECLARATION

class mHandlePutter : public mPutter


{
protected:
mHandlePutter();
public:
virtual void PutInteger( long anInteger );
virtual void PutReal( double aReal );
virtual void PutString( mString &String );
virtual void PutHandle( mHandle& handleValue ) = 0 ;
} ;

CLASS DESCRIPTION
This abstract class is the Superclass of Workers that can accept an mHandle
object.
All Worker Classes for which data of a user defined type can be accepted must
be subclasses of this class.

SEE ALSO
mHandle, page 2-23
mHandleGetter (abstract), page 2-30

REQUIREMENTS
mcore.h, mcore.lib

APTRA Advance ADE, C++ Class Reference 2-33


Runtime Core Classes
mHandlePutter (abstract)

SUPERCLASSES
mPutter (abstract), page 2-43

INHERITED METHODS
PutHandle (deferred) : mPutter (abstract), page 2-44
PutInteger (deferred) : mPutter (abstract), page 2-45
PutReal (deferred) : mPutter (abstract), page 2-45
PutString (deferred) : mPutter (abstract), page 2-46

CLASS METHODS
PutHandle (redeclared, deferred), page 2-34
PutInteger, PutReal, PutString, page 2-34

PutHandle (redeclared, deferred) 2

METHOD DESCRIPTION
This inherited deferred method is redeclared in this class and must be
implemented in a subclass.

PutInteger, PutReal, PutString 2

USE
To block data conversion between Advance ADE Data Types and external data
types.

SYNOPSES
virtual void PutInteger( long anInteger );

virtual void PutReal( double aReal );

2-34 APTRA Advance ADE, C++ Class Reference


Runtime Core Classes
mHandlePutter (abstract)

virtual void PutString( mString &String );

PARAMETERS
anInteger A long integer.
aReal A real number.
&String Reference to an mString object.
These parameters are always ignored.

ERRORS
Invalid Data Conversion, page B-2.

CLASS REFERENCES
mString, page 1-4

METHOD DESCRIPTION
These inherited deferred methods are implemented in this class.
Each always returns an error, thus blocking the data conversion. This data
conversion blocking is designed to stop an external data type being assigned to
an Advance ADE Data Type.

APTRA Advance ADE, C++ Class Reference 2-35


Runtime Core Classes
mIntegerGetter (abstract)

mIntegerGetter (abstract) 2

USE
Base class for Workers which can return an integer.

CLASS DECLARATION
class mIntegerGetter : public mRealGetter
{
protected:
mIntegerGetter();
public:
virtual long GetInteger() = 0;
virtual double GetReal();
virtual mString GetString();
} ;

CLASS DESCRIPTION
This abstract class is the Superclass of Workers that can return a long integer.
Any Worker Class which can return an integer must be a subclass of this class.

SEE ALSO
mIntegerPutter (abstract), page 2-39

REQUIREMENTS
mcore.h, mcore.lib

SUPERCLASSES
mGetter (abstract), page 2-19
mStringGetter (abstract), page 2-62
mRealGetter (abstract), page 2-47

2-36 APTRA Advance ADE, C++ Class Reference


Runtime Core Classes
mIntegerGetter (abstract)

INHERITED METHODS
GetHandle : mStringGetter (abstract), page 2-63
GetInteger (reimplemented) : mRealGetter (abstract), page 2-48
GetReal (redeclared, deferred) : mRealGetter (abstract), page 2-49
GetString : mRealGetter (abstract), page 2-49

CLASS METHODS
GetInteger (redeclared, deferred), page 2-37
GetReal, page 2-37
GetString (reimplemented), page 2-38

GetInteger (redeclared, deferred) 2

METHOD DESCRIPTION
This inherited deferred method is redeclared in this class and must be
reimplemented in a subclass.

GetReal 2

USE
To return the integer value converted to a real number.

SYNOPSIS
virtual double GetReal();

RETURN VALUE
The integer value converted to a real number.

APTRA Advance ADE, C++ Class Reference 2-37


Runtime Core Classes
mIntegerGetter (abstract)

ERRORS
Invalid Data Conversion, page B-2.

METHOD DESCRIPTION
This inherited deferred method is implemented in this class.
It converts the long integer to its own data type or returns an error if the data
conversion fails.

GetString (reimplemented) 2

METHOD DESCRIPTION
This inherited method is reimplemented in this class to convert the long integer
to its own data type. No error can occur with this conversion.

2-38 APTRA Advance ADE, C++ Class Reference


Runtime Core Classes
mIntegerPutter (abstract)

mIntegerPutter (abstract) 2

USE
Base class for Worker Classes which can accept integers.

CLASS DECLARATION

class mIntegerPutter : public mPutter


{
protected:
mIntegerPutter();
public:
virtual void PutHandle(mHandle& aHandle);
virtual void PutReal(double aReal);
virtual void PutString(mString& aString);
virtual void PutInteger(long intValue) = 0 ;
} ;

CLASS DESCRIPTION
This abstract class is the Superclass of Worker Classes that can accept a long
integer.
Any Worker Class which can accept an integer must be a subclass of this class.

SEE ALSO
mIntegerGetter (abstract), page 2-36

REQUIREMENTS
mcore.h, mcore.lib

SUPERCLASSES
mPutter (abstract), page 2-43

APTRA Advance ADE, C++ Class Reference 2-39


Runtime Core Classes
mIntegerPutter (abstract)

INHERITED METHODS
PutHandle (deferred) : mPutter (abstract), page 2-44
PutInteger (deferred) : mPutter (abstract), page 2-45
PutReal (deferred) : mPutter (abstract), page 2-45
PutString (deferred) : mPutter (abstract), page 2-46

CLASS METHODS
PutHandle, page 2-40
PutInteger (redeclared, deferred), page 2-41
PutReal, page 2-41
PutString, page 2-42

PutHandle 2

USE
To block data conversion between Advance ADE Data Types and external data
types.

SYNOPSIS
virtual void PutHandle(mHandle& aHandle);

PARAMETERS
aHandle Reference to an mHandle object. This is always ignored.

ERRORS
Invalid Data Conversion, page B-2.

CLASS REFERENCES
mHandle, page 2-23

2-40 APTRA Advance ADE, C++ Class Reference


Runtime Core Classes
mIntegerPutter (abstract)

METHOD DESCRIPTION
This inherited deferred method is implemented in this class.
It always returns an error, thus blocking the data conversion. This data
conversion blocking is designed to stop an external data type being assigned to
an Advance ADE Data Type.

PutInteger (redeclared, deferred) 2

METHOD DESCRIPTION
This inherited deferred method is redeclared in this class and must be
implemented in a subclass.

PutReal 2

USE
To give a real number to a Worker to be converted to an integer.

SYNOPSIS
virtual void PutReal(double aReal);

PARAMETERS
aReal The real number to be converted.

ERRORS
Invalid Data Conversion, page B-2.

METHOD DESCRIPTION
This inherited deferred method is implemented in this class.
It converts its own data type to a long integer or returns an error if the data
conversion fails.

APTRA Advance ADE, C++ Class Reference 2-41


Runtime Core Classes
mIntegerPutter (abstract)

PutString 2

USE
To give the contents of an mString object’s data array to a Worker to be
converted to an integer.

SYNOPSIS
virtual void PutString(mString& aString);

PARAMETERS
aString Reference to the mString object to be converted.

ERRORS
Invalid Data Conversion, page B-2.

METHOD DESCRIPTION
This inherited deferred method is implemented in this class.
It converts the string data to a long integer or returns an error if the data
conversion fails.

2-42 APTRA Advance ADE, C++ Class Reference


Runtime Core Classes
mPutter (abstract)

mPutter (abstract) 2

USE
To define which Workers can accept data.

CLASS DECLARATION
class mPutter
{
protected:
mPutter();
public:
virtual void PutHandle( mHandle& handleValue ) = 0;
virtual void PutInteger( long intValue ) = 0;
virtual void PutReal( double realValue ) = 0;
virtual void PutString( mString &stringValue ) = 0;
} ;

CLASS DESCRIPTION
This abstract class is the Superclass of Workers that are termed Putters; that is,
Workers that can accept data.
When called, the public methods will accept the data type as implied by their
names.
All the public methods must be implemented in a subclass.

SEE ALSO
mGetter (abstract), page 2-19
mHandle, page 2-23
mString, page 1-4

REQUIREMENTS
mcore.h, mcore.lib

APTRA Advance ADE, C++ Class Reference 2-43


Runtime Core Classes
mPutter (abstract)

SUPERCLASSES
None

CLASS METHODS
PutHandle (deferred), page 2-44
PutInteger (deferred), page 2-45
PutReal (deferred), page 2-45
PutString (deferred), page 2-46

PutHandle (deferred) 2

USE
To give an mHandle object to a Worker.

SYNOPSIS
virtual void PutHandle( mHandle& handleValue ) = 0;

PARAMETERS
handleValue Reference to the mHandle object.

ERRORS
None

CLASS REFERENCES
mHandle, page 2-23

METHOD DESCRIPTION
This method accepts an mHandle object.
This deferred method must be implemented in a subclass.

2-44 APTRA Advance ADE, C++ Class Reference


Runtime Core Classes
mPutter (abstract)

PutInteger (deferred) 2

USE
To give an integer to a Worker.

SYNOPSIS
virtual void PutInteger( long intValue ) = 0;

PARAMETERS
intValue The long integer which is to be given to the Worker.

METHOD DESCRIPTION
This method accepts a long integer.
This deferred method must be implemented in a subclass.

PutReal (deferred) 2

USE
To give a real number to a Worker.

SYNOPSIS
virtual void PutReal( double realValue ) = 0;

PARAMETERS
realValue The double precision floating point number which is to
be given to the Worker.

METHOD DESCRIPTION
This method accepts a double floating point number.
This deferred method must be implemented in a subclass.

APTRA Advance ADE, C++ Class Reference 2-45


Runtime Core Classes
mPutter (abstract)

PutString (deferred) 2

USE
To give an mString object to a Worker.

SYNOPSIS
virtual void PutString( mString &stringValue ) = 0;

PARAMETERS
stringValue Reference to the mString object which is to be given to
the Worker.

ERRORS
None

CLASS REFERENCES
mString, page 1-4

METHOD DESCRIPTION
This method accepts a reference to an mString object.
This deferred method must be implemented in a subclass.

2-46 APTRA Advance ADE, C++ Class Reference


Runtime Core Classes
mRealGetter (abstract)

mRealGetter (abstract) 2

USE
Base class for Worker Classes which can return a real number.

CLASS DECLARATION
class mRealGetter : public mStringGetter
{
protected:
mRealGetter();
public:
virtual long GetInteger();
virtual double GetReal() = 0;
virtual mString GetString();
};

CLASS DESCRIPTION
This abstract class is the Superclass of Worker Classes that can return a real
number.
Any Worker Class which can return a real number must be a subclass of this
class.

SEE ALSO
mRealPutter (abstract), page 2-50

REQUIREMENTS
mcore.h, mcore.lib

SUPERCLASSES
mGetter (abstract), page 2-19
mStringGetter (abstract), page 2-62

APTRA Advance ADE, C++ Class Reference 2-47


Runtime Core Classes
mRealGetter (abstract)

INHERITED METHODS
GetHandle : mStringGetter (abstract), page 2-63
GetInteger : mStringGetter (abstract), page 2-64
GetReal : mStringGetter (abstract), page 2-65
GetString (redeclared, deferred) : mStringGetter (abstract), page 2-65

CLASS METHODS
GetInteger (reimplemented), page 2-48
GetReal (redeclared, deferred), page 2-49
GetString, page 2-49

GetInteger (reimplemented) 2

USE
To convert the real value to a long integer.

SYNOPSES
virtual long GetInteger();

RETURN VALUE
The real number converted to a long integer.

ERRORS
Invalid Data Conversion, page B-2.

METHOD DESCRIPTION
This inherited method is reimplemented in this class.
It converts the real value to its own data type or returns an error if the
conversion fails.

2-48 APTRA Advance ADE, C++ Class Reference


Runtime Core Classes
mRealGetter (abstract)

GetReal (redeclared, deferred) 2

METHOD DESCRIPTION
This inherited method is redeclared in this class and must be reimplemented in
a subclass.

GetString 2

USE
To convert the real value to character data.

SYNOPSIS
virtual mString GetString();

RETURN VALUE
The real number converted to mString-compatible character data.

ERRORS
None.

METHOD DESCRIPTION
This inherited deferred method is implemented in this class.
It converts the real value to its own data type. No errors can occur with this
conversion.

APTRA Advance ADE, C++ Class Reference 2-49


Runtime Core Classes
mRealPutter (abstract)

mRealPutter (abstract) 2

USE
To define which Workers can accept real numbers.

CLASS DECLARATION
class mRealPutter : public mIntegerPutter
{
protected:
mRealPutter();
public:
virtual void PutInteger( long anInteger );
virtual void PutReal( double aReal ) = 0;
virtual void PutString( mString& aString );
};

CLASS DESCRIPTION
This abstract class is the Superclass of Workers that can accept a real number.
Any Worker Class which can accept a real number must be a subclass of this
class.

SEE ALSO
mRealGetter (abstract), page 2-47

REQUIREMENTS
mcore.h, mcore.lib

SUPERCLASSES
mPutter (abstract), page 2-43
mIntegerPutter (abstract), page 2-39

2-50 APTRA Advance ADE, C++ Class Reference


Runtime Core Classes
mRealPutter (abstract)

INHERITED METHODS
PutHandle : mIntegerPutter (abstract), page 2-40
PutInteger (redeclared, deferred) : mIntegerPutter (abstract), page 2-41
PutReal : mIntegerPutter (abstract), page 2-41
PutString : mIntegerPutter (abstract), page 2-42

CLASS METHODS
PutInteger, page 2-51
PutReal (redeclared, deferred), page 2-52
PutString (reimplemented), page 2-52

PutInteger 2

USE
To give an integer to a Worker which converts it to a real.

SYNOPSIS
virtual void PutInteger( long anInteger );

PARAMETERS
anInteger The long integer to be converted.

ERRORS
None.

METHOD DESCRIPTION
This inherited method is implemented in this class.
It converts an integer to its own data type. No error can occur with this
conversion.

APTRA Advance ADE, C++ Class Reference 2-51


Runtime Core Classes
mRealPutter (abstract)

PutReal (redeclared, deferred) 2

METHOD DESCRIPTION
This inherited method is redeclared in this class and must be reimplemented in
a subclass.

PutString (reimplemented) 2

METHOD DESCRIPTION
This inherited method is reimplemented in this class to convert the string data
to a real number.

2-52 APTRA Advance ADE, C++ Class Reference


Runtime Core Classes
mSignal

mSignal 2

USE
To encapsulate the data that is associated with an Advance ADE Signal.

CLASS DECLARATION

class mSignal
{
public:
mSignal( const mSignaller* aSignaller,
const mWorkContext& aSourceContext,
unsigned short aSignalId,
enum SignalPriorityRef aPriorityRef
);
mSignal( const mSignal& aSignalCopy );
virtual const mSignaller* GetSignaller(void ) const;
virtual const mWorkContext* GetWorkContext(void ) const;
virtual unsigned short GetSignalId(void ) const;
virtual unsigned short GetPriority(void ) const;
static unsigned short Get
PriorityConst(
enum SignalPriorityRef aPriorityRef
) const;
};

CLASS DESCRIPTION
An mSignal object is created using the constructor or the copy constructor. The
former creates an object initialised with data for a new Signal, the latter
produces a copy of an existing mSignal object.
This object is created by a Doer Worker whenever it has recognised an Event.
For example, when a Touch Key Worker receives an Event that indicates that a
user has touched a touch key on the SST screen, the Worker instantiates an
mSignal to indicate this.

APTRA Advance ADE, C++ Class Reference 2-53


Runtime Core Classes
mSignal

The class methods allow the retrieval of information about a particular Signal
and its attributes.

SEE ALSO
mDoer (abstract), page 2-4
mSignaller (abstract), page 2-61
mWorkContext, page 2-87

REQUIREMENTS
mcore.h, mcore.lib

SUPERCLASSES
None

CLASS METHODS
Constructor — Default, page 2-54
Constructor — Copy, page 2-56
GetPriority, page 2-56
GetPriorityConst, page 2-57
GetSignalId, page 2-58
GetSignaller, page 2-59
GetWorkContext, page 2-59

Constructor — Default 2

USE
To initialise a new mSignal object with its Signaller, Work Context, Signal ID
and Priority.

2-54 APTRA Advance ADE, C++ Class Reference


Runtime Core Classes
mSignal

SYNOPSIS
mSignal( const mSignaller* aSignaller,
const mWorkContext& aSourceContext,
unsigned short aSignalId,
enum SignalPriorityRef aPriorityRef
);

PARAMETERS
aSignaller Pointer to the Signaller object that has produced the
Signal.
aSourceContext Reference to an mWorkContext object which describes
the Work Context of the Signaller object, when it
generated the Signal. The mSignal object keeps a copy of
the referenced WorkContext object.
aSignalId An integer that is used to identify what type of Signal
was generated. This identifier is used to differentiate
between the different types of Signals that can be
generated.
aPriorityRef One of the values defined for the enumerated type
SignalPriorityRef.

ERRORS
None

DATA REFERENCES
SignalPriorityRef, page A-3

CLASS REFERENCES
mSignaller (abstract), page 2-61
mWorkContext, page 2-87

METHOD DESCRIPTION
This constructor sets up a new mSignal object. In order to do this it has to know
which Worker has Signalled, the Work Context, the Signaller was in when it

APTRA Advance ADE, C++ Class Reference 2-55


Runtime Core Classes
mSignal

Signalled, the Signal identifier (used to distinguish between Signals produced


by the same object) and the Priority of the Signal (which is used to decide
which of the Signals is acted upon).

Constructor — Copy 2

USE
To create an mSignal object using the data from an existing mSignal object.

SYNOPSIS
mSignal( const mSignal& aSignalCopy );

PARAMETERS
aSignalCopy Reference to the existing mSignal object of which the
new mSignal object will be a copy.

METHOD DESCRIPTION
This constructor sets up a copy of an existing mSignal object. The Signaller,
Signal ID, Priority and Work Context of the old mSignal are copied to the new.
Only the Work Context is copied in full. References to the other properties are
placed in the new object.

GetPriority 2

USE
To get the mSignal object’s Priority.

SYNOPSIS
virtual unsigned short GetPriority( void ) const;

2-56 APTRA Advance ADE, C++ Class Reference


Runtime Core Classes
mSignal

RETURN VALUE
The integer value of the mSignal’s Priority. This is a conversion from the
Priority levels defined in the enum SignalPriorityRef type.

ERRORS
None

DATA REFERENCES
SignalPriorityRef, page A-3

METHOD DESCRIPTION
This method returns the value of the Priority assigned to the mSignal object
when it was created. The Priority, which is defined using the enumerated type
SignalPriorityRef, is returned converted to an integer. It is a const method and
thus does nothing to the mSignal object.

GetPriorityConst 2

USE
To convert an enumerated Priority value, SignalPriorityRef, to an integer.

SYNOPSIS
static unsigned short GetPriorityConst(
enum SignalPriorityRef aPriorityRef
) const;

PARAMETERS
aPriorityRef One of the values defined for the enumerated type
SignalPriorityRef.

RETURN VALUE
The integer value equivalent of the supplied SignalPriorityRef value.

APTRA Advance ADE, C++ Class Reference 2-57


Runtime Core Classes
mSignal

ERRORS
None

DATA REFERENCES
SignalPriorityRef, page A-3

METHOD DESCRIPTION
This method converts the SignalPriorityRef enumerated type to its integer
equivalent. It is a const method and thus does nothing to the mSignal object.
This is a static method and is thus available whether an mSignal has been
created or not.

GetSignalId 2

USE
To get the mSignal object’s Signal ID.

SYNOPSIS
virtual unsigned short GetSignalId( void ) const;

RETURN VALUE
The integer value of the Signal ID which is the identifier of the mSignal when it
was created.

METHOD DESCRIPTION
This method returns the value of the Signal ID assigned to the mSignal object
when it was created. It is a const method and thus does nothing to the mSignal
object.

2-58 APTRA Advance ADE, C++ Class Reference


Runtime Core Classes
mSignal

GetSignaller 2

USE
To get the mSignal object’s Signaller.

SYNOPSIS
virtual const mSignaller* GetSignaller( void ) const;

RETURN VALUE
Pointer to the constant Signaller object that has produced the Signal.

ERRORS
None

CLASS REFERENCES
mSignaller (abstract), page 2-61

METHOD DESCRIPTION
This method returns a pointer to the const Signaller object that generated the
Signal. It is a const method and thus does nothing to the mSignal object.

GetWorkContext 2

USE
To get the mSignal object’s Work Context.

SYNOPSIS
virtual const mWorkContext* GetWorkContext( void ) const;

RETURN VALUE
Pointer to the constant Work Context object, which is the Work Context of the
Signaller when it generated the mSignal object.

APTRA Advance ADE, C++ Class Reference 2-59


Runtime Core Classes
mSignal

ERRORS
None

CLASS REFERENCES
mWorkContext, page 2-87

METHOD DESCRIPTION
This method returns a pointer to the const WorkContext object, which was the
Work Context of the Signaller when it generated the Signal. It is a const method
and thus does nothing to the mSignal object.

2-60 APTRA Advance ADE, C++ Class Reference


Runtime Core Classes
mSignaller (abstract)

mSignaller (abstract) 2

USE
Base class for all Signaller Worker Classes.

CLASS DECLARATION
class mSignaller
{
protected:
mSignaller();
};

CLASS DESCRIPTION
This abstract class is the Superclass of Workers that are termed Signallers, that
is, classes which can produce Signals. All classes that require to do this must
inherit from this class.
All Doers are Signallers.

REQUIREMENTS
mcore.h, mcore.lib

SUPERCLASSES
None

CLASS METHODS
None.

APTRA Advance ADE, C++ Class Reference 2-61


Runtime Core Classes
mStringGetter (abstract)

mStringGetter (abstract) 2

USE
To define which Workers can give an mString object.

CLASS DECLARATION

class mStringGetter : public mGetter


{
protected:
mStringGetter();
public:
virtual mHandle GetHandle();
virtual long GetInteger();
virtual double GetReal();
virtual mString GetString() = 0;
} ;

CLASS DESCRIPTION
This abstract class is the Superclass of Workers that can return an mString
object.
All Worker Classes which can return an mString must be subclasses of this
class.

SEE ALSO
mString, page 1-4
mStringPutter (abstract), page 2-66

REQUIREMENTS
mcore.h, mcore.lib

2-62 APTRA Advance ADE, C++ Class Reference


Runtime Core Classes
mStringGetter (abstract)

SUPERCLASSES
mGetter (abstract), page 2-19

INHERITED METHODS
GetHandle (deferred) : mGetter (abstract), page 2-20
GetInteger (deferred) : mGetter (abstract), page 2-21
GetReal (deferred) : mGetter (abstract), page 2-21
GetString (deferred) : mGetter (abstract), page 2-22

CLASS METHODS
GetHandle, page 2-63
GetInteger, page 2-64
GetReal, page 2-65
GetString (redeclared, deferred), page 2-65

GetHandle 2

USE
To block data conversion between Advance ADE Data Types and external data
types.

SYNOPSIS
virtual mHandle GetHandle();

RETURN VALUE
An empty mHandle object.

ERRORS
Invalid Data Conversion, page B-2.

APTRA Advance ADE, C++ Class Reference 2-63


Runtime Core Classes
mStringGetter (abstract)

CLASS REFERENCES
mHandle, page 2-23

METHOD DESCRIPTION
This inherited deferred method is implemented in this class.
This method always returns an error, thus blocking the data conversion. This
data conversion blocking is designed to stop an external data type being
converted to an Advance ADE Data Type.

GetInteger 2

USE
To return the mString data converted to a long integer.

SYNOPSIS
virtual long GetInteger();

RETURN VALUE
The mString data converted to a long integer.

ERRORS
Invalid Data Conversion, page B-2.

CLASS REFERENCES
mString, page 1-4

METHOD DESCRIPTION
These inherited deferred methods are implemented in this class.
It converts the mString data to an integer or returns an error if the data
conversion fails.

2-64 APTRA Advance ADE, C++ Class Reference


Runtime Core Classes
mStringGetter (abstract)

GetReal 2

USE
To return the mString data converted to a real number.

SYNOPSIS
virtual double GetReal();

RETURN VALUE
The mString data converted to a real number.

ERRORS
Invalid Data Conversion, page B-2.

CLASS REFERENCES
mString, page 1-4

METHOD DESCRIPTION
This inherited deferred method is implemented in this class.
It converts the mString data to its own data type or returns an error if the data
conversion fails.

GetString (redeclared, deferred) 2

METHOD DESCRIPTION
This inherited deferred method is redeclared here and must be implemented in
a subclass.

APTRA Advance ADE, C++ Class Reference 2-65


Runtime Core Classes
mStringPutter (abstract)

mStringPutter (abstract) 2

USE
To define which Workers can accept an mString.

CLASS DECLARATION

class mStringPutter : public mRealPutter


{
protected:
mStringPutter();
public:
virtual void PutInteger( long anInteger );
virtual void PutReal( double aReal );
virtual void PutString( mString& aString ) = 0;
} ;

CLASS DESCRIPTION
This abstract class is the Superclass of Workers that can accept an mString
object.
All Worker Classes which can accept an mString must be subclasses of this
class.

SEE ALSO
mIntegerPutter (abstract), page 2-39

REQUIREMENTS
mcore.h, mcore.lib

SUPERCLASSES
mPutter (abstract), page 2-43
mIntegerPutter (abstract), page 2-39

2-66 APTRA Advance ADE, C++ Class Reference


Runtime Core Classes
mStringPutter (abstract)

mRealPutter (abstract), page 2-50

INHERITED METHODS
PutHandle : mIntegerPutter (abstract), page 2-40
PutInteger : mRealPutter (abstract), page 2-51
PutReal (redeclared, deferred) : mRealPutter (abstract), page 2-52
PutString (reimplemented) : mRealPutter (abstract), page 2-52

CLASS METHODS
PutInteger (reimplemented), page 2-67
PutReal (reimplemented), page 2-67
PutString (redeclared, deferred), page 2-68

PutInteger (reimplemented) 2

METHOD DESCRIPTION
This inherited method is reimplemented in this class to convert the integer to
an mString character string. No error can occur with this conversion.

PutReal (reimplemented) 2

METHOD DESCRIPTION
This inherited deferred method is reimplemented in this class to convert the
real number to an mString character string. No error can occur with this
conversion.

APTRA Advance ADE, C++ Class Reference 2-67


Runtime Core Classes
mStringPutter (abstract)

PutString (redeclared, deferred) 2

METHOD DESCRIPTION
This inherited method is redeclared in this class and must be reimplemented in
a subclass.

2-68 APTRA Advance ADE, C++ Class Reference


Runtime Core Classes
mTBasicWorkGroup (template)

mTBasicWorkGroup (template) 2

USE
Class template used to create a Work Group that does not contain any Doer
Workers but has other types of Subworkers, for instance Putter and Getter
Workers.

CLASS DECLARATION

template<class SubWorkerClass>
class mTBasicWorkGroup : public mWorkGroup
{
public:
mTBasicWorkGroup( const unsigned short Size=2 );
virtual SubWorkerClass* GetWorker( unsigned short Index ) const;
virtual unsigned short GetNumWorkers() const;
};

CLASS DESCRIPTION
This class template is used to define an mTBasicWorkGroup that stores
Workers of a particular type as an ordered list. This Worker type is defined
using the template parameter SubWorkerClass.
The class methods allow the manipulation of the mTBasicWorkGroup ordered
list of SubWorkerClass Workers.
GetWorker returns a pointer to a particular Worker on the list, and
GetNumWorkers returns the number of Workers on the list.
For implementation details, see the APTRA Advance ADE, Programmer’s Guide.

SEE ALSO
mDoer (abstract), page 2-4
mPutter (abstract), page 2-43

APTRA Advance ADE, C++ Class Reference 2-69


Runtime Core Classes
mTBasicWorkGroup (template)

mGetter (abstract), page 2-19

REQUIREMENTS
mcore.h, mcore.lib

SUPERCLASSES
mWorkGroup (abstract), page 2-96

INHERITED METHODS
None

CLASS METHODS
Constructor, page 2-70
GetNumWorkers, page 2-71
GetWorker, page 2-71

Constructor 2

USE
To initialise a new mTBasicWorkGroup.

SYNOPSIS
mTBasicWorkGroup( const unsigned short Size=2 );

PARAMETERS
Size This unsigned short defines the initial size of the
dynamic array, with a default of 2.

METHOD DESCRIPTION
This method is used to create a new mTBasicWorkGroup with an empty list of
Workers. This Work Group can have Subworkers of type SubWorkerClass,
where SubWorkerClass is the class template parameter.

2-70 APTRA Advance ADE, C++ Class Reference


Runtime Core Classes
mTBasicWorkGroup (template)

A dynamic array is used as the physical representation of the logical Worker


list. The Size parameter sets up the initial size of this array.

GetNumWorkers 2

USE
To get the number of Workers in the Work Group.

SYNOPSIS
virtual unsigned short GetNumWorkers() const;

RETURN VALUE
The unsigned short value of the number of Workers on the Work Group list.

METHOD DESCRIPTION
This method returns the number of Workers on the workgroup list.
This method does not change the Work Group.

GetWorker 2

USE
To get a Worker from a Work Group.

SYNOPSIS
virtual SubWorkerClass* GetWorker( unsigned short Index ) const;

PARAMETERS
Index This unsigned short is the position of the Worker on the
Work Group list. The value is 0 or greater.

APTRA Advance ADE, C++ Class Reference 2-71


Runtime Core Classes
mTBasicWorkGroup (template)

RETURN VALUE
A pointer to a Worker of type SubWorkerClass that is at the list position given
by the Index value.

ERRORS
Index Error If a NULL pointer is returned, this indicates that the
Index value does not represent the position of a Worker
on the list. This error is not sent to the Advance ADE
error handling utility.

DATA REFERENCES
NULL, page A-2

METHOD DESCRIPTION
This method is used to get a pointer to a Worker of type SubWorkerClass
(which is the mTBasicWorkGroup template parameter) which is the Worker
whose position on the list is defined by the Index value. The first Worker on the
list has an Index of 0.
If the position on the list defined by the Index value does not exist, a NULL
SubWorkerClass pointer is returned.
This method does not change the Work Group.

2-72 APTRA Advance ADE, C++ Class Reference


Runtime Core Classes
mTDoerWorkGroup (template)

mTDoerWorkGroup (template) 2

USE
Class template used to create a Work Group which has Doer Subworkers.

CLASS DECLARATION

template <class mDoerClass>


class mTDoerWorkGroup : public mTBasicWorkGroup<mDoerClass>
{
public:
mTDoerWorkGroup( const unsigned short Size=2 );
virtual void BroadcastStart(mEventContext* aEventContext,
mWorkContext& aWorkContext,
mWorkContext* aForwardContext
);
virtual mSignal* BroadcastStop( mEventContext* aEventContext,
mWorkContext& aWorkContext
);
virtual mSignal* BroadcastEvent( mEventContext* aEventContext,
mWorkContext& aWorkContext,
const mEvent* aEvent
);
void Activated();
void Deactivated();
BOOLEAN IsActive();
};

CLASS DESCRIPTION
This class template is used to define an mTDoerWorkGroup that stores Doer
Workers as an ordered list. This Doer Worker type is defined using the
template parameter mDoer Class.
This class has three methods, BroadcastStart, BroadcastStop and
BroadcastEvent which are used to execute the Start, Stop and ProcessEvent
methods, of the Subworkers that are Doers in the Work Group.

APTRA Advance ADE, C++ Class Reference 2-73


Runtime Core Classes
mTDoerWorkGroup (template)

This class also defines a process which is used to inform the APTRA Author
about the activation state of a Work Group. This is done through the Activated
and Deactivated methods. The method IsActive reports on the activation status
of the Work Group.
For implementation details, see the APTRA Advance ADE, Programmer’s Guide.

SEE ALSO
mDoer (abstract), page 2-4

REQUIREMENTS
mcore.h, mcore.lib

SUPERCLASSES
mTBasicWorkGroup (template), page 2-69

INHERITED METHODS
GetNumWorkers : mTBasicWorkGroup (template), page 2-71
GetWorker : mTBasicWorkGroup (template), page 2-71

CLASS METHODS
Constructor, page 2-75
Activated, page 2-75
BroadcastEvent, page 2-76
BroadcastStart, page 2-78
BroadcastStop, page 2-79
Deactivated, page 2-81
IsActive, page 2-81

2-74 APTRA Advance ADE, C++ Class Reference


Runtime Core Classes
mTDoerWorkGroup (template)

Constructor 2

USE
To initialise a new mTDoerWorkGroup.

SYNOPSIS
mTDoerWorkGroup( const unsigned short Size=2 );

PARAMETERS
Size This unsigned short defines the initial size of the
dynamic array, with a default of 2.

ERRORS
None

CLASS REFERENCES
mDoer (abstract), page 2-4

METHOD DESCRIPTION
This method is used to create a new mTDoerWorkGroup with an empty list of
Workers. This Work Group can have Subworkers of type mDoerClass, where
mDoerClass is the class template parameter.
A dynamic array is used as the physical representation of the logical Worker
list. The Size parameter sets up the initial size of this array.
If the initial Size is 0, no dynamic array is created.

Activated 2

USE
To inform the APTRA Author that the Work Group has been activated.

APTRA Advance ADE, C++ Class Reference 2-75


Runtime Core Classes
mTDoerWorkGroup (template)

SYNOPSIS
void Activated();

METHOD DESCRIPTION
This method is executed to inform the APTRA Author that the
mTDoerWorkGroup has been activated.
This method must be called by the Work Group whenever its Subworkers are
activated.
This method should never be called by user code unless the user has subclassed
from mTDoerWorkGroup in which case the user code must invoke this method
when the Work Group is activated.

BroadcastEvent 2

USE
To broadcast an mEvent to all the Doer Workers in the mTDoerWorkGroup.

SYNOPSIS
virtual mSignal* BroadcastEvent( mEventContext* aEventContext,
mWorkContext& aWorkContext,
const mEvent* aEvent );

PARAMETERS
aEventContext Pointer to the mEventContext which is to be used to post
mEvents.
aWorkContext Reference to the mWorkContext which has a list of the
mWorkGroups that the mEvent has to pass through to
get to this Work Group.
aEvent Pointer to the mEvent that is processed.

RETURN VALUE
A pointer to an mSignal or a NULL pointer if no mSignal is generated.

2-76 APTRA Advance ADE, C++ Class Reference


Runtime Core Classes
mTDoerWorkGroup (template)

ERRORS
None

DATA REFERENCES
NULL, page A-2

CLASS REFERENCES
mEventContext (abstract), page 2-12
mWorkContext, page 2-87
mDoer (abstract), page 2-4

METHOD DESCRIPTION
This method is executed to pass an mEvent to all the Doer Workers in the
mTDoerWorkGroup. The Subworkers are passed the mEvent sequentially,
starting with the Worker which is the first entry in the Worker array.
The first two parameters are used to define the activation context of the
Subworkers, as follows:
● a pointer to the mEventContext which is to be used to post mEvents
● a reference to its mWorkContext which is the hierarchical list of the
mWorkGroups through which the mEvent has passed to get to this Work
Group.
The third parameter is a pointer to the mEvent that it has to process.
These arguments are all passed to the mDoer class ProcessEvent method. A
self-reference is added to the end of the mWorkContext before the
ProcessEvent methods of the Doers are called, and removed when they have all
processed the mEvent.
The method returns a pointer with two possible values: a pointer to an mSignal
which has been generated by one of the Subworkers, or a NULL pointer
indicating that there was no mSignal generated by a Subworker.
If the Subworkers can produce more than one mSignal, Signal Priority can be
used to choose between them. If there are two mSignals with the same Priority

APTRA Advance ADE, C++ Class Reference 2-77


Runtime Core Classes
mTDoerWorkGroup (template)

another methodology has to be imposed to separate them; mTDoerWorkGroup


does it by using the position of the Worker in the Work Group (the first Worker
in the Work Group has the highest Priority, the last has the lowest).

BroadcastStart 2

USE
To activate all the Doer Workers in the mTDoerWorkGroup.

SYNOPSIS
virtual void BroadcastStart( mEventContext* aEventContext,
mWorkContext& aWorkContext,
mWorkContext* aForwardContext
);

PARAMETERS
aEventContext Pointer to the mEventContext which is to be used to post
mEvents.
aWorkContext Reference to the mWorkContext which has a list of the
mWorkGroups that have been activated in order to get
to this Worker.
aForwardContext Reserved by NCR.

ERRORS
None

CLASS REFERENCES
mEventContext (abstract), page 2-12
mWorkContext, page 2-87
mDoer (abstract), page 2-4

2-78 APTRA Advance ADE, C++ Class Reference


Runtime Core Classes
mTDoerWorkGroup (template)

METHOD DESCRIPTION
This method is executed to activate all the Doer Workers in the
mTDoerWorkGroup. The Subworkers are activated sequentially starting with
the first entry in the list of Workers.
Its parameters are used to define the activation context of the Subworkers, as
follows:
● a pointer to the mEventContext which is to be used to post mEvents
● a pointer to its mWorkContext (the hierarchical list of the mWorkGroups
that have been activated to get to this Work Group)
● its Forward Context which is reserved by NCR.
These arguments are all passed to the mDoer class Start method. A
self-reference is added to the end of the mWorkContext before the Start
methods of the Doers are called, and removed when they have all been
activated.
The method has no return value.

BroadcastStop 2

USE
To deactivate all the Doer Workers in the mTDoerWorkGroup.

SYNOPSIS
virtual mSignal* BroadcastStop( mEventContext* aEventContext,
mWorkContext& aWorkContext );

PARAMETERS
aEventContext Pointer to the mEventContext which is to be used to get
and post mEvents.
aWorkContext Reference to the mWorkContext which has a list of the
Work Groups that the message to deactivate has had to
pass through in order to get to this Worker.

APTRA Advance ADE, C++ Class Reference 2-79


Runtime Core Classes
mTDoerWorkGroup (template)

RETURN VALUE
A pointer to a late mSignal or a NULL pointer if no mSignal is generated.

ERRORS
None

DATA REFERENCES
NULL, page A-2

CLASS REFERENCES
mEventContext (abstract), page 2-12
mWorkContext, page 2-87
mDoer (abstract), page 2-4

METHOD DESCRIPTION
This method is executed to deactivate all the Doer Workers in the
mTDoerWorkGroup. The Subworkers are deactivated sequentially starting
with the last entry in the list of Workers.
Its parameters are used to define the deactivation context of the Subworkers:
● a pointer to the mEventContext which is to be used to post and get mEvents
● a pointer to its mWorkContext which is the hierarchical list of the
mWorkGroups which have been deactivated to get to this Work Group.
These arguments are all passed to the mDoer class Stop method A
self-reference is added to the end of the mWorkContext before the Stop
methods of the Doers are called, and removed when they have all been
deactivated.
This method is responsible for checking whether a late mSignal has been
generated by one of its Subworkers. If a late mSignal has been generated, a
pointer to is returned, otherwise a NULL pointer is returned. For more
information on late mSignals, see the mDoer (abstract) class method Stop
(deferred).

2-80 APTRA Advance ADE, C++ Class Reference


Runtime Core Classes
mTDoerWorkGroup (template)

If the Subworkers can produce more than one mSignal, Signal Priority can be
used to choose between them. If there are two late mSignals with the same
Priority another methodology has to be imposed to separate them;
mTDoerWorkGroup does it by using the position of the Worker in the Work
Group (the first Worker in the Work Group has the highest Priority, the last has
the lowest).

Deactivated 2

USE
To inform the APTRA Author that the Work Group has been deactivated.

SYNOPSIS
void Deactivated();

METHOD DESCRIPTION
This method is executed to inform the APTRA Author that the
mTDoerWorkGroup has been deactivated.
This method must be called by the Work Group whenever its Subworkers are
deactivated.
This method should never be called by user code unless the user has subclassed
from mTDoerWorkGroup in which case the user code must invoke this method
when the Work Group is deactivated.

IsActive 2

USE
To check whether the Work Group is currently active.

SYNOPSIS
BOOLEAN IsActive();

APTRA Advance ADE, C++ Class Reference 2-81


Runtime Core Classes
mTDoerWorkGroup (template)

RETURN VALUE
A BOOLEAN with the following possible values:
TRUE The mTDoerWorkGroup is active.
FALSE The mTDoerWorkGroup is not active.

DATA REFERENCES
BOOLEAN, page A-2

METHOD DESCRIPTION
This method is executed to find whether the Work Group is active or not. The
method returns TRUE if it is active.

2-82 APTRA Advance ADE, C++ Class Reference


Runtime Core Classes
mUserEvent

mUserEvent 2

USE
To enable Workers to send Events to active Workers in the application
including themselves.

CLASS DECLARATION
class IMP_OR_EXP mUserEvent : public mEvent
{
public:
mUserEvent( const mConcreteWorker* Sender, const UserMsg* aMsg );
~mUserEvent( void );

const mConcreteWorker* GetSender( void ) const;


UserMsg* GetMsg( void ) const;

};

CLASS DESCRIPTION
An mUserEvent object is created using the constructor. This stores the actual
data content of the Event and information about the originator or sender of the
Event.
This is normally used to indicate that some Worker action has occurred but it
cannot be Signalled at that point. For example, because the mDoer’s Start
method cannot return an mSignal, an mDoer must send itself an mUserEvent
to cause its ProcessEvent method to be executed to handle the Event and
generate an mSignal.
mUserEvents are got from and posted to the Event Queue by the
mEventContext (abstract) class methods GetUserEvent and PostEvent.
When an mUserEvent object is created, because it is a subclass of the mEvent
class, a unique Event ID is created. The accessor method inherited from the
mEvent class will return the unique Event ID.

APTRA Advance ADE, C++ Class Reference 2-83


Runtime Core Classes
mUserEvent

Methods are supplied which will return the Event type, the sender and the data
message contained in the mUserEvent object.

SEE ALSO
mEventContext (abstract), page 2-12

REQUIREMENTS
mcore.h, mcore.lib

SUPERCLASSES
mEvent (abstract), page 1-2

INHERITED METHODS
GetID : mEvent (abstract), page 1-3

CLASS METHODS
Constructor, page 2-84
GetMsg, page 2-85
GetSender, page 2-86

Constructor 2

USE
To initialise a User Event.

SYNOPSIS
mUserEvent( const mConcreteWorker* Sender, const UserMsg* aMsg );

PARAMETERS
Sender Pointer that is used to identify the originator of the
Event.

2-84 APTRA Advance ADE, C++ Class Reference


Runtime Core Classes
mUserEvent

aMsg Pointer to the Event’s message data.

ERRORS
None

DATA REFERENCES
UserMsg, page A-5

METHOD DESCRIPTION
This constructor sets up a new User Event object, initialising it with a copy of
the data message and the originator of the Event.
The contents and format of the message data must be defined by the developer
of the User Event.

GetMsg 2

USE
To get a copy of the mUserEvent’s message.

SYNOPSIS
UserMsg* GetMsg( void ) const;

RETURN VALUE
A pointer to a copy of the mUserEvent’s message.

ERRORS
None

DATA REFERENCES
UserMsg, page A-5

APTRA Advance ADE, C++ Class Reference 2-85


Runtime Core Classes
mUserEvent

METHOD DESCRIPTION
This method returns a pointer to a copy of the mUserEvent’s message.
The message copy is in a data area which is the caller’s responsibility to delete,
when the caller has finished with it. This method does not change the Event.

GetSender 2

USE
To get a pointer to the originator Event.

SYNOPSIS
const mConcreteWorker* GetSender( void ) const;

RETURN VALUE
A pointer to the originator of the Event.

METHOD DESCRIPTION
This method returns a pointer to the originator of the Event.
This method does not change the Event.

2-86 APTRA Advance ADE, C++ Class Reference


Runtime Core Classes
mWorkContext

mWorkContext 2

USE
To store an ordered list of mWorkGroups. This class is used to define the
context in which a Doer is active.

CLASS DECLARATION
class mWorkContext
{
public:
mWorkContext();
mWorkContext( const mWorkContext& aWorkContext );
mWorkContext& operator=( const mWorkContext& aWorkContext );
void Add( mWorkGroup* aWorkGroup );
void SetEnd( mWorkGroup* aWorkGroup );
mWorkGroup* RemoveLast();
mWorkGroup* RemoveFirst();
mWorkGroup* GetWG( const unsigned short Index ) const;
mWorkGroup* GetLastWG( void ) const;
};

CLASS DESCRIPTION
The mWorkContext class is used to define a Work Context which stores
mWorkGroups as an ordered list. For example, when an mSignal is produced
by a Doer, the context of the Signaller is determined by the Work Context
which is passed to the mSignal object.
An mWorkContext object is created using the constructor or the copy
constructor, the former being used to produce an object initialised with data for
a new Signal, the latter producing an object that is a copy of an existing Signal.
The class methods allow the manipulation of the ordered list of mWorkGroups.
Add adds an mWorkGroup to the start of the list, SetEnd manipulates the end
of the list, RemoveLast removes the last Work Group, RemoveFirst removes the

APTRA Advance ADE, C++ Class Reference 2-87


Runtime Core Classes
mWorkContext

first, GetWG returns a pointer to a particular mWorkGroup on the list and


GetLastWG returns a pointer to the last mWorkGroup on the list.
There is also an overloaded assignment operator used for copying one
mWorkContext into another.
Knowledge of this class will not be required for most development work within
the Advance ADE environment.

SEE ALSO
mWorkGroup (abstract), page 2-96

REQUIREMENTS
mcore.h, mcore.lib

SUPERCLASSES
None

CLASS METHODS
Constructor — Default, page 2-89
Constructor — Copy, page 2-89
Overloaded Assignment Operator, page 2-90
Add, page 2-90
GetLastWG, page 2-91
GetWG, page 2-92
RemoveFirst, page 2-93
RemoveLast, page 2-94
SetEnd, page 2-94

2-88 APTRA Advance ADE, C++ Class Reference


Runtime Core Classes
mWorkContext

Constructor — Default 2

USE
To initialise a new mWorkContext.

SYNOPSIS
mWorkContext();

METHOD DESCRIPTION
This constructor sets up a new mWorkContext object. This object is created
with no mWorkGroups in the list.

Constructor — Copy 2

USE
To create an mWorkContext object using the data from an existing
mWorkContext object.

SYNOPSIS
mWorkContext( const mWorkContext& aWorkContext );

PARAMETERS
aWorkContext Reference to the existing mWorkContext object of which
the new mWorkContext will be a copy.

METHOD DESCRIPTION
This constructor sets up a copy of an existing mWorkContext object. This
constructor does not make a separate copy of the mWorkGroups in the list but
shares them with the original mWorkContext.

APTRA Advance ADE, C++ Class Reference 2-89


Runtime Core Classes
mWorkContext

Overloaded Assignment Operator 2

USE
To copy one mWorkContext object to another.

SYNOPSIS
mWorkContext& operator=( const mWorkContext& aWorkContext );

PARAMETERS
aWorkContext Reference to the existing mWorkContext object to be
copied.

RETURN VALUE
The new mWorkGroup that is a copy of the original.

METHOD DESCRIPTION
This constructor copies an existing mWorkContext object to another. This
constructor does not make a separate copy of the mWorkGroups in the list but
shares them with the original mWorkContext.

Add 2

USE
To add an mWorkGroup to the mWorkContext.

SYNOPSIS
void Add( mWorkGroup* aWorkGroup );

PARAMETERS
aWorkGroup Pointer to the mWorkGroup to be added to the
mWorkContext’s list.

2-90 APTRA Advance ADE, C++ Class Reference


Runtime Core Classes
mWorkContext

ERRORS
None

DATA REFERENCES
NULL, page A-2

METHOD DESCRIPTION
This method adds an mWorkGroup to the start of the mWorkContext’s list of
mWorkGroups. The mWorkGroup to be added is given by the aWorkGroup
pointer.
If a WorkGroup pointer is NULL no mWorkGroup is added.

GetLastWG 2

USE
To get the last mWorkGroup from the mWorkContext’s list of mWorkGroups.

SYNOPSIS
mWorkGroup* GetLastWG( void ) const;

RETURN VALUE
A pointer to the mWorkGroup that is the last on the list.

ERRORS
None

DATA REFERENCES
NULL, page A-2

METHOD DESCRIPTION
This method is used to get a pointer to the mWorkGroup whose position is last
on the list.

APTRA Advance ADE, C++ Class Reference 2-91


Runtime Core Classes
mWorkContext

If there are no mWorkGroups on the list a NULL is returned.


This method does not change the mWorkContext.

GetWG 2

USE
To get an mWorkGroup from the mWorkContext’s list of mWorkGroups.

SYNOPSIS
mWorkGroup* GetWG( const unsigned short Index ) const;

PARAMETERS
Index The position of the mWorkGroup on the list. The value is
0 or greater.

RETURN VALUE
A pointer to the mWorkGroup that is at the list position given by the Index
value.

ERRORS
Index Error Caused by the Index value not corresponding with the
position of an mWorkGroup on the list.
The indication that this has occurred is that the returned
mWorkGroup pointer is NULL. This error is not sent to
the Advance ADE error handling utility.

DATA REFERENCES
NULL, page A-2

2-92 APTRA Advance ADE, C++ Class Reference


Runtime Core Classes
mWorkContext

METHOD DESCRIPTION
This method is used to get a pointer to an mWorkGroup whose position on the
list is defined by the Index value. The first mWorkGroup on the list has an
Index of 0.

If the position on the list defined by the Index value does not exist, a NULL
pointer is returned.
This method does not change the mWorkContext.

RemoveFirst 2

USE
To remove the first mWorkGroup from the mWorkContext’s list of
mWorkGroups.

SYNOPSIS
mWorkGroup* RemoveFirst();

RETURN VALUE
A pointer to the mWorkGroup that was removed from the start of the list of
mWorkGroups.

ERRORS
None

DATA REFERENCES
NULL, page A-2

METHOD DESCRIPTION
This method removes the mWorkGroup that is the first in the list of
mWorkGroups. It returns a pointer to the mWorkGroup that has been removed
from the list.
If there is no mWorkGroup on the list a NULL pointer is returned.

APTRA Advance ADE, C++ Class Reference 2-93


Runtime Core Classes
mWorkContext

RemoveLast 2

USE
To remove the last mWorkGroup from the mWorkContext’s list of
mWorkGroups.

SYNOPSIS
mWorkGroup* RemoveLast();

RETURN VALUE
A pointer to the mWorkGroup that was removed from the end of the list of
mWorkGroups.

ERRORS
None

DATA REFERENCES
NULL, page A-2

METHOD DESCRIPTION
This method removes the mWorkGroup that is the last in the list of
mWorkGroups. It returns a pointer to the mWorkGroup that has been
removed.
If there is no mWorkGroup on the list a NULL pointer is returned.

SetEnd 2

USE
To manipulate the end of the mWorkContext’s list of mWorkGroups.

SYNOPSIS
void SetEnd( mWorkGroup* aWorkGroup );

2-94 APTRA Advance ADE, C++ Class Reference


Runtime Core Classes
mWorkContext

PARAMETERS
aWorkGroup Pointer to the mWorkGroup to be added to the end of
mWorkContext’s list. It is valid for the pointer to be
NULL.

ERRORS
None

DATA REFERENCES
NULL, page A-2

METHOD DESCRIPTION
This method manipulates the end of the list of mWorkGroups. The
manipulation of the Work Group list by this method is dependent on whether
the mWorkGroup, pointed to by the aWorkGroup parameter, is already on the
list or not, as follows.
If the mWorkGroup to be added to the list is already on the list, all the
mWorkGroups after it on the list are removed, leaving it the last on the list.
If the mWorkGroup to be added to the list is not already on the list, it is
appended to the end of the list.
If a WorkGroup pointer is NULL all mWorkGroups are removed from the list.

APTRA Advance ADE, C++ Class Reference 2-95


Runtime Core Classes
mWorkGroup (abstract)

mWorkGroup (abstract) 2

USE
Base class for all Work Group classes.

CLASS DECLARATION
class mWorkGroup:
{
protected:
mWorkGroup();
};

CLASS DESCRIPTION
This abstract base class defines which classes are Work Groups. All concrete
subclasses of this class provide a common interface to an ordered set of Worker
Classes. The Worker Classes in the set will be of a specific type.
All Work Group classes must be a subclass of this class.

SEE ALSO
mTBasicWorkGroup (template), page 2-69
mTDoerWorkGroup (template), page 2-73

REQUIREMENTS
mcore.h, mcore.lib

SUPERCLASSES
None

CLASS METHODS
None

2-96 APTRA Advance ADE, C++ Class Reference


Appendices

Appendix A Data Types

Appendix B Error Messages

Appendix C Advance ADE Class Names and Identifiers

Appendix D ADI-2 Extensions

Appendix E Related Documentation

APTRA Advance ADE, C++ Class Reference


APTRA Advance ADE, C++ Class Reference
Table of Contents
Data Types

Appendix A
Data Types

Overview A-1

Advance ADE Simple Data Types A-2

SignalPriorityRef A-3

UserMsg A-5

APTRA Advance ADE, C++ Class Reference


Table of Contents
Data Types

APTRA Advance ADE, C++ Class Reference


Data Types
A

Overview

Overview A

This appendix describes the data types used when programming in the Advance ADE
environment, as defined in the header files for the supplied Advance ADE C++ classes.
The “Advance ADE Simple Data Types” section contains descriptions of the simple
Advance ADE data types. It does not include the C++ fundamental types.
The other sections describe the complex Advance ADE data types.

APTRA Advance ADE, C++ Class Reference A-1


Data Types
Advance ADE Simple Data Types

Advance ADE Simple Data Types A

BOOLEAN
An 8 bit data type that supports the logical values TRUE and FALSE. The
values must be supplied in upper case.

BYTE
A C language ‘char’ value.

NULL
A NULL constant.

TCHAR
Type CHARacter: a cross-platform data type used to represent character
strings. Defined as WCHAR and used to represent the WCHAR type in
Advance ADE.

WCHAR
Wide CHARacter: a 16 bit character data type which can contain Unicode
values from 0 to 65,535.

A-2 APTRA Advance ADE, C++ Class Reference


Data Types
SignalPriorityRef

SignalPriorityRef A

USE
The SignalPriorityRef type is used to represent the eight possible Signal
Priority levels in Advance ADE.

SYNOPSIS
enum SignalPriorityRef{ SysExceptionPriority,
MediaAcceptPriority,
AutoAckPriority,
UIPriority,
SupervisorPriority,
NetworkPriority,
LowDevicePriority,
InternalEventPriority
};

DESCRIPTION
This type consists of a C enum construct with eight elements representing
Signal Priority levels in order of decreasing priority, as follows:
SysExceptionPriority The highest priority level, assigned to any Signal
that indicates a high priority system exception,
for example, tampering with the SST.
MediaAcceptPriority The priority level for Signals indicating that the
SST has accepted input of customer media, for
example, a card being input and accepted.
AutoAckPriority The priority level for Signals indicating that a
customer has received an automatic response to
interaction with the SST keyboard or touch
display, for example, touching a key and
receiving an audio beep in response.

APTRA Advance ADE, C++ Class Reference A-3


Data Types
SignalPriorityRef

UIPriority The priority level for Signals that indicate a


customer interaction with the SST other than
MediaAccept, or an interaction which will have
an automatic acknowledgment, for example,
removal of a card.
SupervisorPriority The priority level for Signals indicating that an
operator has interacted with the supervisor mode
switch. This is a lower priority than a customer
related activity since honouring a customer’s
transaction is more important.
NetworkPriority The priority level for Signals indicating that a
message on a communications link has arrived.
LowDevicePriority The priority level Signals concerning all input
and output interactions with devices and all error
Signals for the device handling classes, not
involving user interaction.
InternalEventPriority The lowest priority level, used for Signals which
are generated internally within an application as
a result of an event which is not a device event,
for example, a time-out.

A-4 APTRA Advance ADE, C++ Class Reference


Data Types
UserMsg

UserMsg A

USE
The UserMsg type is used to format User Event messages.

SYNOPSIS
typedef struct
{
BYTE Length;
BYTE Data[1];
} UserMsg;

DESCRIPTION
This type consists of a C struct construct with two elements:
Length The length of the data message, from 0 to 255 BYTEs
Data The message text

DATA REFERENCES
BYTE on page A-2

APTRA Advance ADE, C++ Class Reference A-5


Data Types
UserMsg

A-6 APTRA Advance ADE, C++ Class Reference


Table of Contents
Error Messages

Appendix B
Error Messages

Overview B-1

Invalid Data Conversion B-2

APTRA Advance ADE, C++ Class Reference


Table of Contents
Error Messages

APTRA Advance ADE, C++ Class Reference


Error Messages B

Overview

Overview B

This appendix lists the error codes generated and sent to the Advance ADE error
handling utility by the classes and the corresponding error messages generated by the
error handling utility.

APTRA Advance ADE, C++ Class Reference B-1


Error Messages
Invalid Data Conversion

Invalid Data Conversion B

ERROR CODE
177

DESCRIPTION
An Invalid Data Conversion error occurs when an attempt is made to convert a
value from one data type to another under circumstances which cause the
attempted conversion to fail.
Data type conversions will fail in the following circumstances:
String to Integer Fails if the String contains non-numeric
characters or represents a non-integer number, or
if the value of the number is too large
String to Real Fails if the String contains non-numeric
characters, or the value of the number is too large
Real to Integer Fails if the Real is not equal to an integer value, or
the value is too large
Handle to Advance ADE typeAlways fails as conversions from external data
types to Advance ADE data types are prohibited
Advance ADE type to HandleAlways fails as conversions from Advance ADE
data types to external data types are prohibited.

B-2 APTRA Advance ADE, C++ Class Reference


Table of Contents
Advance ADE Class Names and Identifiers

Appendix C
Advance ADE Class Names
and Identifiers

Overview C-1

Advance ADE Class Names and Identifiers C-2

APTRA Advance ADE, C++ Class Reference


Table of Contents
Advance ADE Class Names and Identifiers

APTRA Advance ADE, C++ Class Reference


Advance ADE Class Names and Identifiers
C

Overview

Overview C

This appendix contains a table listing the Class Names and Class Identifiers of the
Advance ADE classes in this publication.

APTRA Advance ADE, C++ Class Reference C-1


Advance ADE Class Names and Identifiers
Advance ADE Class Names and Identifiers

Advance ADE Class Names and Identifiers C

Table C-1 Class Name Class Identifier


Advance ADE Class Names
and Identifiers Basic Work Group mTBasicWorkGroup

Concrete Worker mConcreteWorker

Doer mDoer

Doer Work Group mTDoerWorkGroup

Event mEvent

Event Context mEventContext

Giver mGetter

Handle mHandle

Handle Giver mHandleGetter

Handle Receiver mHandlePutter

Integer Giver mIntegerGetter

Integer Receiver mIntegerPutter

Real Giver mRealGetter

Real Receiver mRealPutter

Receiver mPutter

Signal mSignal

Signaller mSignaller

String mString

String Giver mStringGetter

String Receiver mStringPutter

C-2 APTRA Advance ADE, C++ Class Reference


Advance ADE Class Names and Identifiers
Advance ADE Class Names and Identifiers

Class Name Class Identifier

User Event mUserEvent

Work Context mWorkContext

Work Group mWorkGroup

APTRA Advance ADE, C++ Class Reference C-3


Advance ADE Class Names and Identifiers
Advance ADE Class Names and Identifiers

C-4 APTRA Advance ADE, C++ Class Reference


Table of Contents
ADI-2 Extensions

Appendix D
ADI-2 Extensions

Overview D-1

ADI_M_SETUP_MONITOR D-2

APTRA Advance ADE, C++ Class Reference


Table of Contents
ADI-2 Extensions

APTRA Advance ADE, C++ Class Reference


ADI-2 Extensions
D

Overview

Overview D

This appendix contains the function extensions to ADI-2 introduced for Advance ADE.
It extends the information on ADI-2 Interfacing in the APTRA Self-Service Support,
Programmers’ Reference.

APTRA Advance ADE, C++ Class Reference D-1


ADI-2 Extensions
ADI_M_SETUP_MONITOR

ADI_M_SETUP_MONITOR D

USE
To monitor channels and services for solicited and unsolicited events.

SYNOPSIS
ADI_M_SETUP_MONITOR( unsigned short system_address )

PARAMETERS
system_address The same parameter as used in the
ADI_SETUP_MONITOR call.

RETURN VALUE
GOOD

The system address is now being monitored by this client.

DESCRIPTION
This call is an extension of ADI_SETUP_MONITOR and allows the
monitoring of both channels and services.
It monitors for solicited and unsolicited events on a channel and from a
service.

REQUIREMENTS
ooADIm.h
uladi2x.h
uladi2x.lib

D-2 APTRA Advance ADE, C++ Class Reference


Table of Contents
Related Documentation

Appendix E
Related Documentation

Overview E-1

Advance ADE Documentation E-2

Other NCR Documentation E-5

APTRA Advance ADE, C++ Class Reference


Table of Contents
Related Documentation

APTRA Advance ADE, C++ Class Reference


Related DocumentationE

Overview

Overview E

In this appendix we identify NCR documentation you


may find useful when developing your Advance ADE
application and installing it on an SST.
The documentation is a combination of on-line help files
and Adobe™ Acrobat™ Portable Document Format
(PDF) files. To read the PDF documentation, you need
the Acrobat™ Reader version 3.0 or later.
In general, documentation is provided with its respective
product.

APTRA Advance ADE, C++ Class Reference E -1


Related Documentation
Advance ADE Documentation

Advance ADE Documentation E

Product Title Format Description

APTRA APTRA Advance ADE, PDF Provides a brief and general


Advance General Description description of Advance ADE.
ADE B006-6035

APTRA Advance ADE, PDF Describes the project management


Organising the Team features provided by Advance ADE
B006-6036 and introduces the different
approaches you can adopt when
developing an Advance ADE
application.

APTRA Advance ADE, PDF Describes the process involved in


Local Language localising elements of the Advance
Customisation Guide ADE user interface.
B006-6037

APTRA Advance ADE, PDF Describes how to install and use the
User’s Guide APTRA Author and Runtime
B006-6038 Components to design, develop
and maintain a self-service
application.

APTRA Advance ADE, PDF Identifies the functionality offered


Seed Application User’s by the Advance ADE Seed
Guide Application and describes how to
B006-6039 use/customise it.

APTRA Advance ADE, PDF Describes how application


Programmer’s Guide programmers should create their
B006-6042 own C++ Worker Classes. It also
contains information on using C
routines to manipulate data.

E-2 APTRA Advance ADE, C++ Class Reference


Related Documentation
Advance ADE Documentation

Product Title Format Description

APTRA Advance ADE, PDF Provides application programmers


C++ Class Reference with definitions for a number of
B006-6043 C++ Runtime and Utility Worker
Classes provided by NCR.

APTRA Author Help Windows Context-sensitive help for the


Help Author user interface and
authoring errors.

Runtime Core Help Windows Context-sensitive help for the


Help Runtime Core Authoring
components and runtime errors,
which are part of Advance Core
Self-Service.

GUI Help Windows Context-sensitive help for the GUI


Help Authoring components, which are
part of Advance Core Self-Service.

Self-Service Core Help Windows Context-sensitive help for the


Help Self-Service Core Authoring
components, which are part of
Advance Core Self-Service.

ActiveX™ Help Windows Context-sensitive help for the


Help ActiveX™ Authoring components
and runtime errors, which are part
of Advance Core Self-Service.

Basic Self-Service Help Windows Context-sensitive help for the


Help Authoring components provided
with Advance Basic Self-Service.

ATM Help Windows Context-sensitive help for the


Help Authoring components and
runtime errors provided with
Advance ATM.

APTRA Advance ADE, C++ Class Reference E-3


Related Documentation
Advance ADE Documentation

Product Title Format Description

Special Self-Service Windows Context-sensitive help for the


Help Help Authoring components and
runtime errors provided with
Advance Special Self-Service.

Statement Printer Help Windows Context-sensitive help for the


Help Authoring components and
runtime errors provided with
Advance Statement Printer.

APTRA Passbook Printer Help Windows Context-sensitive help for the


Advance Help Authoring components and
Passbook runtime errors provided with
Advance Passbook Printer.

E-4 APTRA Advance ADE, C++ Class Reference


Related Documentation
Other NCR Documentation

Other NCR Documentation E

Product Title Format Description

SST Device personaS SST Device Paper This publication describes how to
Simulator Simulator For Windows use the SST Device Simulator to test
NT™, User’s Guide a self-service application under
B006-6041 development.

personaS SST Device Windows Context-sensitive help for the SST


Simulator For Windows Help Device Simulator.
NT™ Help

APTRA Advance ADE, C++ Class Reference E-5


Related Documentation
Other NCR Documentation

E-6 APTRA Advance ADE, C++ Class Reference


Glossary

APTRA Advance ADE, C++ Class Reference


APTRA Advance ADE, C++ Class Reference
Glossary

Glossary

abstract A class that can only be used as a superclass for


A other classes. An object of this class cannot be created.
activation The state a Doer Worker goes into when it is
started.
ADI Application Development Interface: Self-Service
Support API for interfacing to devices.
Advance ADE APTRA Advance Application
Development Environment
Advance ADE Application A user-created application that
has been developed using the APTRA Author,
containing Workers and Work Groups, that carries out
some task.
Application See Advance ADE Application.
APTRA Author The Advance ADE software tool used to
develop Applications. It supports the creation, editing
and testing of Applications.

Basic Work Group This type of Work Group can contain


B all Workers that are not Doers. The Work Group is an
instance of the mBasicWorkGroup class template.

cardholder The SST customer.


C
Class ID The unique class identifier assigned to each
class as it is introduced into the Author.
Component ID A variable length string that has a unique
value for all the components in the environment.

APTRA Advance ADE, C++ Class Reference Glossary-1


Glossary

Concrete Worker A concrete Worker Class is one that can


be instantiated. To work correctly in the Advance ADE
environment a concrete Worker Class must be a subclass
of the mConcreteWorker class.
Coordinator A type of Worker which can coordinate the
work of Subworkers contained in one or more Work
Groups.

deactivation The state an active Worker goes into when it


D is stopped.
delete When used in reference to objects, this term
implies that the object has been completely cleared from
memory. Compare with remove.
DLL A Dynamic Link Library, that is a library that can
be linked at execution time.
Doer A Worker Class that can be activated, deactivated
and can also process events. A Worker Class must be a
subclass of mDoer to be a Doer.
Doer Work Group This type of Work Group can contain
only Doer Workers. The Work Group is an instance of
the mDoerWorkGroup class template.

Event An occurrence in the SST system that the software


E must handle. Events are encapsulated in a C++ object
which is a subclass of the mEvent class.
Event Context This defines the context in which the
Workers get and receive events. See mEventContext
class.
Event ID The unique identifier associated with each
event.

Glossary-2 APTRA Advance ADE, C++ Class Reference


Glossary

Event processing The process whereby a Doer Worker


handles an event.
Event Queue The queue that events are posted to and
taken from.

FIFO First In First Out. A protocol in which the first item


F placed in a list, queue or container is the first to be
removed.

Getter Name of the Worker Classes that can give data.


G This Worker is a subclass of the class mGetter.

Handle Device used to enable Advance ADE classes to


H have access to external data types.
Handle Getter A Worker that can return a handle. This
Worker must be a subclass of the mHandleGetter class.
Handle ID A unique identifier assigned to each of the
external data types.
Handle Putter A Worker that can accept a handle. This
Worker must be a subclass of the mHandlePutter class.

instantiated When an instance of a class is created it is


I said that the object has been instantiated.
Integer Getter A Worker that can return an integer. This
Worker must be a subclass of the mIntegerGetter class.
Integer Putter A Worker that can accept an integer. This
Worker must be a subclass of the mIntegerPutter class.

late signal A signal sent by a Worker which received a


L late event.

APTRA Advance ADE, C++ Class Reference Glossary-3


Glossary

late event An event that a Worker got from the event


queue while it was deactivating.

mString An object that can contain many forms of


M characters in different forms of arrays. It is defined by
the mString class.

parent The object that is higher up in a hierarchical


P structure than the child object.
SHUVRQD6 Range of NCR SSTs and associated products.
Putter A Worker Class that can receive data.
priority See Signal Priority.

real number A double precision floating point real


R number.
remove When used in reference to objects, this term
implies that only a reference to the object has been
removed and the object remains in memory. Compare
with delete.
Real Getter A Worker that can return a real. This Worker
must be a subclass of the mRealGetter class.
Real Putter A Worker that can accept a real. This Worker
must be a subclass of the mRealPutter class.

Self-Service Support A 32-bit open software platform


S supplied by NCR for use on SSTs.
sharing The way objects share data rather than repeating
the same data when a copy is made of it. If changes are
made to shared data, the other objects sharing the data
automatically get the modified data.

Glossary-4 APTRA Advance ADE, C++ Class Reference


Glossary

Signal This is generated by a doer Worker to indicate to


its coordinator that something has occurred. It is an
instantiation of the mSignal class.
Signal ID The signal identifier (ID) is used to differentiate
between different signals from the same object.
Signaller Any Worker that can generate a signal and that
is a subclass of the mSignaller class.
Signal Priority This is used to differentiate between
signals by their importance. A high priority signal is
more important than a low priority one and has to be
handled more quickly. The meaning of the different
priorities is defined by the data type SignalPriorityRef.
SST Self Service Terminal.
string A null terminated character array.
String Getter A Worker that can return an mString. This
Worker must be a subclass of the mStringGetter class.
String Putter A Worker that can accept an mString. This
Worker must be a subclass of the mStringPutter class.
Subworker Any worker that is in a Work Group. It is said
to be a Subworker of the Coordinator of the Work
Group.
Superclass A class from which another class inherits, in
relation to the inheriting class.

thread A linked execution sequence within a process in a


T multi-tasking operating environment.

User Event An event produced by the user’s own code.


U

APTRA Advance ADE, C++ Class Reference Glossary-5


Glossary

User Message The message contained with the User


Event. This is normally defined by the UserMsg
structure.

Work Context The list of Work Groups an event must


W pass through to get to a particular Worker. An
instantiation of the mWorkContext class.
Work Group A group of Workers that are all executed
concurrently. This must be a subclass of the
mWorkGroup class.
Worker The different Worker Class objects that can be
executed in a Application.
Worker Class Name given to classes that have been
introduced into the Author environment.

Glossary-6 APTRA Advance ADE, C++ Class Reference


Index

APTRA Advance ADE, C++ Class Reference


APTRA Advance ADE, C++ Class Reference
Index

Index 0

!= operator
Symbols mString class 1-21
+ operator
mString class 1-23
+= operator
mString class 1-22
= operator
mString class
assign integer 1-18
assign mString 1-16
assign real 1-19
assign single character 1-17
assign single wide character 1-18
assign string 1-18
mWorkContext class
assign mWorkContext 2-90
== operator
mString class 1-20–1-21

Activated
A member function 2-75
Add
member function 2-90
ADI-2 Extensions D-1
ADI_M_SETUP_MONITOR D-2
function extensions D-1
ADI-2 Functions
ADI_M_SETUP_MONITOR D-2
ADI-2 Interfacing D-1
Advance ADE Classes Class Descriptions-iii, Class
Descriptions-v
asInteger
member function 1-34

APTRA Advance ADE, C++ Class Reference Index-1


Index

asReal
member function 1-35

Basic Work Group


B Class Name of mTBasicWorkGroup C-2
BOOLEAN
data type A-2
BroadcastEvent
member function 2-76
BroadcastStart
member function 2-78
BroadcastStop
member function 2-79
BYTE 1-15
data type A-2

char 1-17
C Component ID 2-3
Concrete Worker
Class Name of mConcreteWorker C-2

data types A-1


D BOOLEAN A-2
BYTE A-2
NULL A-2
SignalPriorityRef A-3
TCHAR A-2
UserMsg A-5
WCHAR A-2
Deactivated
member function 2-81
DisposeEvent
member function 2-14, 2-17
Doer 2-6–2-8, 2-10, 2-17, 2-53, 2-61, 2-69, 2-79, 2-87
activation 2-8
Class Name of mDoer C-2
deactivation 2-10
Doer Subworker 2-75–2-76, 2-78–2-79, 2-81

Index-2 APTRA Advance ADE, C++ Class Reference


Index

Doer Work Group 2-75


activation test 2-75
broadcast an Event 2-76
broadcast the Start message 2-78
broadcast the Stop message 2-79
Class Name of mTDoerWorkGroup C-2
inform Author of deactivation 2-81
test for active Work Group 1-2, 2-81
Doer Worker Classes
mDoer 2-4

Error Code
E 177 B-2
Error Messages B-1
Invalid Data Conversion B-2
Event 2-9–2-10, 2-14, 2-76, 2-78
Class Name of mEvent C-2
disposal 2-14
getting a User Event 2-16
ID 1-3
posting 2-17
processing 2-7
Event classes
mEvent 1-2
mEventContext 2-12
mUserEvent 2-83
Event Context 2-6–2-7, 2-9–2-10, 2-12, 2-15, 2-78–2-79
Class Name of mEventContext C-2
Event Queue 2-14, 2-16–2-17
EventDefault
member function 2-5
external data 2-23, 2-25–2-29, 2-31–2-32, 2-34–2-35, 2-40–2-41,
2-63–2-64

FindStr
F member function 1-29–1-30

APTRA Advance ADE, C++ Class Reference Index-3


Index

Get Signaller
G member function 2-59
GetData
mHandle member function
with type checking 2-26
without type checking 2-27
GetHandle
mGetter member function 2-20
mHandle member function 2-63
GetID
mEvent member function 1-3
mHandle member function 2-27
GetInteger
mGetter member function 2-21
mHandleGetter member function 2-32
mIntegerGetter member function 2-37
mRealGetter member function 2-48
GetLastWG
member function 2-91
GetLength
member function 1-31
GetMsg
member function 2-85
GetNumWorkers
member function 2-71
GetPriority
member function 2-56
GetPriorityConst
member function 2-57
GetReal
mGetter member function 2-21
mHandleGetter member function 2-32
mIntegerGetter member function 2-37
mRealGetter member function 2-49
GetSender
member function 2-86
GetSignalID
member function 2-58

Index-4 APTRA Advance ADE, C++ Class Reference


Index

GetString
mGetter member function 2-22
mHandleGetter member function 2-32
mIntegerGetter member function 2-38
mRealGetter member function 2-49
Getter 2-19, 2-30, 2-69
Getter Worker Classes
mGetter 2-19
mHandleGetter 2-30
mIntegerGetter 2-36
mRealGetter 2-47
mStringGetter 2-62
GetUserEvent 2-14
member function 2-16
GetWG
member function 2-92
GetWorkContext
member function 2-59
GetWorker
member function 2-71
Giver
Class Name of mGetter C-2

Handle
H Class Name of mHandle C-2
Handle Giver
Class Name of mHandleGetter C-2
Handle ID 2-23, 2-25–2-26, 2-28
Handle Receiver
Class Name of mHandlePutter C-2

InsertStr
I member function 1-24
integer 1-12, 1-18, 1-32, 1-34, 2-21, 2-36–2-37, 2-39, 2-41–2-42,
2-45, 2-51
Integer Giver
Class Name of mIntegerGetter C-2
Integer Receiver
Class Name of mIntegerPutter C-2

APTRA Advance ADE, C++ Class Reference Index-5


Index

Invalid Data Conversion Error B-2


IsActive
member function 2-81
IsInteger
member function 1-32
IsReal
member function 1-33

late Signal 2-10–2-11, 2-80


L late User Events 2-12

mConcreteWorker class 2-2


M Class ID of Concrete Worker C-2
SetId 2-3
mDoer 2-77, 2-79–2-80
mDoer Worker Class 2-4
Class ID of Doer C-2
EventDefault 2-5
ProcessEvent 2-7
Start 2-8
Stop 2-10
mEvent 2-9–2-10, 2-76, 2-78
default handler 2-5
ID 1-3
mEvent class 1-2
Class ID of Event C-2
Constructor
default 1-3
GetID 1-3
mEventContext 2-6–2-7, 2-9–2-10, 2-78–2-79
mEventContext class 2-12
Class ID of Event Context C-2
Constructor 2-13
DisposeEvent 2-14
GetParentEventContext 2-15
GetUserEvent 2-16
PostEvent 2-17

Index-6 APTRA Advance ADE, C++ Class Reference


Index

mGetter Worker Class 2-19


Class ID of Giver C-2
GetHandle 2-20
GetInteger 2-21
GetReal 2-21
GetString 2-22
mHandle 2-20, 2-30, 2-33, 2-44
mHandle class 2-23
Class ID of Handle C-2
Constructor
copy 2-25
default 2-24
GetData
with type checking 2-26
without type checking 2-27
GetID 2-27
PutData
with type checking 2-28
without type checking 2-29
mHandleGetter Worker Class 2-30
Class ID of Handle Giver C-2
GetInteger 2-32
GetReal 2-32
GetString 2-32
mHandlePutter Worker Class 2-33
Class ID of Handle Receiver C-2
mIntegerGetter Worker Class 2-36
Class ID of Integer Giver C-2
GetInteger 2-37
GetReal 2-37
GetString 2-38
mIntegerPutter Worker Class 2-39
Class ID of Integer Receiver C-2
PutHandle 2-40
PutReal 2-41
PutString 2-42

APTRA Advance ADE, C++ Class Reference Index-7


Index

mPutter Worker Class 2-43


Class ID of Receiver C-2
PutHandle 2-44
PutInteger 2-45
PutReal 2-45
PutString 2-46
mRealGetter Worker Class 2-47
Class ID of Real Giver C-2
GetInteger 2-48
GetReal 2-49
GetString 2-49
mRealPutter Worker Class 2-50
Class ID of Real Receiver C-2
PutInteger 2-51
PutReal 2-52
PutString 2-52
mSignal 2-6–2-7, 2-17, 2-77, 2-87
late 2-11, 2-16, 2-80
mSignal class 2-53
Class ID of Signal C-2
Constructor
copy 2-56
default 2-54
GetPriority 2-56
GetPriorityConst 2-57
GetSignalId 2-58
GetSignaller 2-59
GetWorkContext 2-59
mSignaller 2-4
mSignaller class 2-61
Class ID of Signaller C-2
mString 2-22, 2-25, 2-28, 2-32, 2-46, 2-62, 2-66
Class ID of String C-2

Index-8 APTRA Advance ADE, C++ Class Reference


Index

mString class
!= operator 1-21
+ operator 1-23
+= operator 1-22
= operator
assign integer 1-18
assign mString 1-16
assign real 1-19
assign single character 1-17
assign single wide character 1-18
assign string 1-18
== operator - Character 1-20
== operator - Wide Character 1-20–1-21
asInteger 1-34
asReal 1-35
comparisons
!= 1-21
== 1-20–1-21
Constructor
multi-BYTE array 1-15
converting mString
to a real 1-35
to an integer 1-34
converting to mString
from a real 1-19
from a single character 1-17
from a string 1-18
from a wide character 1-18
from an integer 1-18
copy mString to mString 1-16
Destructor 1-16
Export - Byte 1-28
Export - Character 1-27
Export - Wide Character 1-27
FindStr 1-29–1-30
FindStr - Character 1-29
GetLength 1-31
InsertStr - Character 1-24
InsertStr - Wide Character 1-24
IsInteger 1-32

APTRA Advance ADE, C++ Class Reference Index-9


Index

IsReal 1-33
manipulating mString
concantenate two mStrings together 1-22–1-23
copy part of the mString 1-26–1-27
insert mString into another mString 1-24
parsing 1-30–1-31
replace part of mString with new mString 1-25
Parse - Character 1-30
Parse - Wide Character 1-30–1-31
queries
how long is it? 1-31
is it a real? 1-33
is it an integer? 1-32
ReplaceStr 1-25
searching
find mString 1-29–1-30
SubStr - Character 1-26
SubStr - Wide Character 1-26
mStringGetter Worker Class 2-62
Class ID of String Giver C-2
GetHandle 2-63
mStringPutter Worker Class 2-66
Class ID of String Receiver C-2
PutInteger 2-67
PutReal 2-67
PutString 2-68
mTBasicWorkGroup class template 2-69
Class ID of Basic Work Group C-2
Constructor 2-70
GetNumWorkers 2-71
GetWorker 2-71
mTDoerWorkGroup class template
Activated 2-75
BroadcastEvent 2-76
BroadcastStart 2-78
BroadcastStop 2-79
Class ID of Doer Work Group C-2
Constructor 2-75
Deactivated 2-81
IsActive 2-81

Index-10 APTRA Advance ADE, C++ Class Reference


Index

multi-BYTE character 1-15


mUserEvent 2-11, 2-14, 2-16
posting 2-17
mUserEvent class 2-83
Class ID of User Event C-3
Constructor 2-84
GetMsg 2-85
GetSender 2-86
mWorkContext 2-6–2-7, 2-9–2-10, 2-77, 2-79
mWorkContext class 2-87
= operator 2-90
Add 2-90
Class ID of Work Context C-3
Constructor
copy 2-89
default 2-89
GetLastWG 2-91
GetWG 2-92
RemoveFirst 2-93
RemoveLast 2-94
SetEnd 2-94
mWorkGroup 2-87, 2-89–2-94
mWorkGroup class 2-96
Class ID of Work Group C-3

NULL
N data type A-2

Parse
P member function 1-30–1-31
PostEvent
member function 2-17
ProcessEvent 2-17, 2-77
member function 2-7
PutData
mHandle member function
with type checking 2-28
without type checking 2-29

APTRA Advance ADE, C++ Class Reference Index-11


Index

PutHandle
mIntegerPutter member function 2-40
mPutter member function 2-44
PutInteger
mPutter member function 2-45
mRealPutter member function 2-51
mStringPutter member function 2-67
PutReal
mIntegerPutter member function 2-41
mPutter member function 2-45
mRealPutter member function 2-52
mStringPutter member function 2-67
PutString
mIntegerPutter member function 2-42
mPutter member function 2-46
mRealPutter member function 2-52
mStringPutter member function 2-68
Putter 2-39, 2-69
Putter Worker Classes
mHandlePutter 2-33
mIntegerPutter 2-39
mPutter 2-43
mRealPutter 2-50
mStringPutter 2-66

real 1-13, 1-19, 1-33, 1-35, 2-21, 2-37, 2-45, 2-47–2-51


R Real Giver
Class Name of mRealGetter C-2
Real Receiver
Class Name of mRealPutter C-2
Receiver
Class Name of mPutter C-2
RemoveFirst
member function 2-93
RemoveLast
member function 2-94
ReplaceStr
member function 1-25

Index-12 APTRA Advance ADE, C++ Class Reference


Index

SetEnd
S member function 2-94
SetId
member function 2-3
Shared Store Worker 2-2
Shared Worker 2-2
Signal 2-7, 2-17, 2-53, 2-59–2-60, 2-77, 2-87
Class Name of mSignal C-2
late 2-11, 2-16, 2-80
Signal classes
mSignal 2-53
Signal handling classes
mSignaller 2-61
Signal ID 2-54, 2-56, 2-58
Signal Priority 2-56–2-58, A-3
AutoAckPriority A-3
InternalEventPriority A-4
LowDevicePriority A-4
MediaAcceptPriority A-3
NetworkPriority A-4
SupervisorPriority A-4
SysExceptionPriority A-3
UIPriority A-4
Signaller 2-54, 2-56, 2-59–2-61, 2-87
Class Name of mSignaller C-2
SignalPriorityRef 2-55, 2-57
data type A-3
SST 2-53
Start
member function 2-8, 2-79
Stop
member function 2-10, 2-16, 2-80
String
Class Name of mString C-2
string 1-11, 1-18
String Giver
Class Name of mStringGetter C-2
String Receiver
Class Name of mStringPutter C-2

APTRA Advance ADE, C++ Class Reference Index-13


Index

SubStr
member function 1-26–1-27
Subworker 2-69–2-70, 2-72

TCHAR
T data type A-2
Touch Key Worker 2-53

User Event 2-11, 2-14, 2-16


U Class Name of mUserEvent C-3
message structure A-5
UserMsg
data type A-5
Utility Classes
mHandle 2-23
mString 1-4

WCHAR
W data type A-2
wide character 1-13, 1-18
TCHAR data type A-2
WCHAR data type A-2
wide character array 1-10
Work Context 2-6–2-7, 2-9–2-10, 2-55–2-56, 2-59, 2-77, 2-79
Class Name of mWorkContext C-3
Work Group 2-9, 2-11, 2-69–2-72, 2-87, 2-96
Class Name of mWorkGroup C-3
Work Group Classes
mTBasicWorkGroup 2-69
mTDoerWorkGroup 2-73
mWorkGroup 2-96

Index-14 APTRA Advance ADE, C++ Class Reference


Index

Worker Classes
mDoer 2-4
mGetter 2-19
mHandleGetter 2-30
mHandlePutter 2-33
mIntegerGetter 2-36
mIntegerPutter 2-39
mPutter 2-43
mRealGetter 2-47
mRealPutter 2-50
mStringGetter 2-62
mStringPutter 2-66

APTRA Advance ADE, C++ Class Reference Index-15


Index

Index-16 APTRA Advance ADE, C++ Class Reference


User Feedback Form

Title: APTRA Advance ADE, C++ Class Reference

Number: B006-6043-B000 Date: March 2003


Cut

NCR welcomes your feedback on this publication. Your comments can be of great value in
helping us improve our information products.

You may send your comments to us electronically. See over for details.

Circle the numbers below that best represent your opinion of this publication.

Ease of use 5 4 3 2 1 0 5 = Excellent


Accuracy 5 4 3 2 1 0 4 = Good
Clarity 5 4 3 2 1 0 3 = Adequate
Completeness 5 4 3 2 1 0 2 = Fair
Organization 5 4 3 2 1 0 1 = Poor
Appearance 5 4 3 2 1 0 0 = Not Applicable
Examples 5 4 3 2 1 0
Illustrations 5 4 3 2 1 0
Job performance 5 4 3 2 1 0
Question resolution 5 4 3 2 1 0
Overall satisfaction 5 4 3 2 1 0

Indicate the ways you feel we could improve this publication.

❑ Improve the table of contents ❑ Add more/better quick reference aids


❑ Improve the overview/introduction ❑ Add more examples
❑ Improve the organization ❑ Add more illustrations
❑ Improve the index ❑ Add more step-by-step procedures
❑ Make it less technical ❑ Add more troubleshooting information
❑ Make it more concise/brief ❑ Add more detail
Write any additional comments you may have below and on additional sheets, if necessary.
Include page numbers where applicable.

Fold
Use the following address to send your comments to us electronically:
e-mail - [email protected]

Cut
If we may contact you concerning your comments, please fill in the information below:

Name
Organisation:
Company:
Address:

Phone: Fax:

Thank you for your evaluation of this publication. Fold the form where indicated, tape
(please do not staple), affix stamp and drop in the mail.
F8763-0695
Fold

Affix
Postage
Stamp
Here

NCR Financial Solutions Group Ltd.


Information Solutions Feedback
Kingsway West
Dundee
Scotland
DD2 3XX

You might also like