AAO DRAMA/DRAMA2 C++ Interface
DRAMA C++11 and later interface

◆ Get() [1/2]

template<long int MinVal = LONG_MIN, long int MaxVal = LONG_MAX, long int DefaultVal = 0>
virtual void drama::gitarg::Int< MinVal, MaxVal, DefaultVal >::Get ( const sds::Id Id,
const long  Min,
const long  Max,
const std::string &  Name = "Argument1",
const int  Position = 1,
const long int  Default = DefaultVal,
const Flags  flags = Flags::KeepErr 
)
inlinevirtual

Get the value of the object from an SDS structure.

The value is fetched from the named item (arg #2) within the SDS structure specified. or the Position (constructor arg #3) item in the
structure if the item named does not exist.

This overload of Get() allows an override of the the class specific Min and Max values, which may be needed in some designs.

Note
The DRAMA lock must be taken when executing this. If in a thread, the preference is to take it by constructing a drama::AccessDrama object to ensure the action context is correct.
Parameters
IdThe SDS structure.
MinThe minimum acceptable value.
MaxThe maximum acceptable value.
NameThe name of the item within the structure.
PositionIf the item does not exist by the name, then presume this position.
DefaultThe default value.
flagsWhich GIT Flags to apply. If you specify KeepErr, then an exception is throw if the value in the SDS structure is invalid. If you don't specify KeepErr and and the SDS structure does not contain a value item, then the value is set to the supplied default.

References drama::CreateRunDramaTask(), and drama::Default.