WSF
WsfEM_AttenuationTypes Class Reference

#include <WsfEM_AttenuationTypes.hpp>

Inheritance diagram for WsfEM_AttenuationTypes:
Collaboration diagram for WsfEM_AttenuationTypes:

Static methods to return a reference to the type list associated with a scenario.

typedef std::function< WsfEM_Attenuation *(const std::string &)> Factory
typedef std::list< FactoryObjectFactoryList
static WSF_EXPORT WsfEM_AttenuationTypesGet (WsfScenario &aScenario)
 Return a modifiable reference to the type list associated with the specified scenario.
static WSF_EXPORT const WsfEM_AttenuationTypesGet (const WsfScenario &aScenario)
 Return a const reference to the type list associated with the specified scenario.
 WsfEM_AttenuationTypes (WsfScenario &aScenario)
WSF_EXPORT void AddObjectFactory (const Factory &aFactory)
LoadResult LoadType (UtInput &aInput) override
bool LoadReference (UtInput &aInput, WsfStringId &aTypeName)
WsfEM_AttenuationClone (WsfStringId aTypeName) const override

Additional Inherited Members

Public Types inherited from WsfObjectTypeList< WsfEM_Attenuation >
typedef WsfEM_Attenuation ObjectType
typedef std::vector< WsfEM_Attenuation * > ObjectPtrList
Public Types inherited from WsfObjectTypeListBase
enum  Flags {
  cREDEFINITION_ALLOWED = 1 , cSINGULAR_BASE_TYPE = 2 , cOBJECT_FACTORY_BASE = 4 , cNO_DELAY_LOAD = 8 ,
  cSIGNATURE_FLAGS = cREDEFINITION_ALLOWED | cNO_DELAY_LOAD
}
Public Types inherited from WsfObjectTypeListBaseI
typedef std::vector< WsfStringIdTypeIdList
Public Member Functions inherited from WsfObjectTypeList< WsfEM_Attenuation >
 WsfObjectTypeList (WsfScenario &aScenario, unsigned int aFlags, const std::string &aBlockName)
bool Add (WsfStringId aId, std::unique_ptr< WsfEM_Attenuation > aDefinitionPtr)
bool AddCoreType (WsfStringId aId, std::unique_ptr< WsfEM_Attenuation > aDefinitionPtr)
WsfEM_AttenuationClone (WsfStringId aId) const override
WsfEM_AttenuationFind (WsfStringId aId) const override
ObjectPtrList GetCoreTypes () const
 Returns a list of core types, i.e. types added via AddCoreType.
void GetCurrentTypes (ObjectPtrList &aListOfPtrs) const
void GetCurrentUserTypes (ObjectPtrList &aListOfPtrs) const
 Returns the list of types defined by the user (no core / builtin types).
bool IsType (WsfStringId aTypeName) const
void SetSingularBaseType ()
void SetObjectFactory (const FACTORY_LIST *aFactoryListPtr)
void SetObjectFactoryDefault ()
bool ProcessInput (UtInput &aInput) override
virtual bool InitializeType (ObjectType *aTypePtr)
bool LoadNamedComponent (UtInput &aInput, WsfPlatform &aPlatform, bool aIsAdding, int aRole)
bool LoadUnnamedComponent (UtInput &aInput, WsfPlatform &aPlatform, bool aIsAdding, int aRole)
bool LoadUnnamedComponentWithoutEdit (UtInput &aInput, WsfPlatform &aPlatform, bool aIsAdding, int aRole)
bool DeleteNamedComponent (UtInput &aInput, WsfPlatform &aPlatform, int aRole)
bool DeleteUnnamedComponent (UtInput &aInput, WsfPlatform &aPlatform, int aRole)
Public Member Functions inherited from WsfObjectTypeListBase
 WsfObjectTypeListBase (const WsfObjectTypeListBase &)=delete
WsfObjectTypeListBaseoperator= (const WsfObjectTypeListBase &)=delete
 WsfObjectTypeListBase (unsigned int aFlags, const std::string &aBlockName=std::string(), WsfScenario *aScenarioPtr=nullptr)
 ~WsfObjectTypeListBase () override
void Clear () override
 Clear (Erase) all type entries.
void GetTypeIds (TypeIdList &aListOfIds) const override
 Return a vector of the type identifiers currently being controlled by this list.
bool ProcessInput (UtInput &aInput) override
int Size () const
 Return the current number of types being maintained by the list.
const std::string & GetBlockName () const override
WsfScenarioGetScenario () const
Public Member Functions inherited from WsfObjectTypeListBaseI
virtual ~WsfObjectTypeListBaseI ()=default
virtual void CompleteLoad ()
Protected Types inherited from WsfObjectTypeListBase
typedef std::map< WsfStringId, std::unique_ptr< WsfObject > > TypeMap
bool InitializeTypeP (WsfObject *aObjectPtr) override
Protected Member Functions inherited from WsfObjectTypeListBase
WsfDeferredInputGetDeferredInput () const
bool CanDelayLoad () const
bool AddP (WsfStringId aId, std::unique_ptr< WsfObject > aDefinitionPtr)
WsfObjectCloneP (WsfStringId aId) const
virtual WsfObjectFindP (WsfStringId aId) const
bool LoadTypeP (UtInput &aInput, WsfObject *&aLoadedObjectPtr)
virtual bool DeferredLoadTypeP (UtInput &aInput, WsfObject *&aLoadedObjectPtr)
bool DeleteComponentP (UtInput &aInput, WsfPlatform &aPlatform, int aRole, bool aIsNamed)
bool LoadComponentP (UtInput &aInput, WsfPlatform &aPlatform, bool aIsAdding, int aRole, bool aIsNamed, bool aIsEditable)
Static Protected Member Functions inherited from WsfObjectTypeList< WsfEM_Attenuation >
static WsfObjectCreateDefaultFunction ()
static WsfObjectCreateFunction ()
static WsfObjectFactoryCreateFunction (void *aListPtr, const std::string &aTypeName)
Protected Attributes inherited from WsfObjectTypeListBase
TypeMap mTypeMap
std::vector< std::unique_ptr< WsfObject > > mRedefinedTypes
 A list of type objects that have been redefined.
std::set< WsfStringIdmCoreTypes
unsigned int mFlags
const std::string mBlockName
WsfObject *(* mCreateSingularTypeFunction )()
WsfObject *(* mFactoryCreateFunction )(void *aListPtr, const std::string &aTypeName)
WsfObject *(* mFactoryCreateDefault )()
void * mFactoryPtr
WsfScenariomScenarioPtr

Member Typedef Documentation

◆ Factory

typedef std::function<WsfEM_Attenuation*(const std::string&)> WsfEM_AttenuationTypes::Factory

◆ ObjectFactoryList

Constructor & Destructor Documentation

◆ WsfEM_AttenuationTypes()

Member Function Documentation

◆ AddObjectFactory()

void WsfEM_AttenuationTypes::AddObjectFactory ( const Factory & aFactory)

Add an object factory for creating an instance from a fundamental type. The factory should be a static method and should be added only once.

Referenced by WsfMilExtension::AddedToScenario(), and WsfEM_AttenuationTypes().

◆ Clone()

WsfEM_Attenuation * WsfEM_AttenuationTypes::Clone ( WsfStringId aTypeName) const
overridevirtual

Create a clone of a type object of a given name.

The returned object can either be used an instance of the specified type or as a base on which to create a new derived type.

Parameters
aTypeNameThe name of a type object that is to be cloned.
Returns
A pointer to the clone of the requested type or 0 if the requested type does not exist.

Implements WsfObjectTypeListBase.

References WsfObjectTypeList< T >::Clone().

Referenced by WsfEM_XmtrRcvr::Initialize().

◆ Get() [1/2]

const WsfEM_AttenuationTypes & WsfEM_AttenuationTypes::Get ( const WsfScenario & aScenario)
static

Return a const reference to the type list associated with the specified scenario.

References WsfScenario::GetEM_AttenuationTypes(), and WsfEM_AttenuationTypes().

◆ Get() [2/2]

WsfEM_AttenuationTypes & WsfEM_AttenuationTypes::Get ( WsfScenario & aScenario)
static

Return a modifiable reference to the type list associated with the specified scenario.

References WsfScenario::GetEM_AttenuationTypes(), and WsfEM_AttenuationTypes().

Referenced by WsfMilExtension::AddedToScenario(), WsfEM_XmtrRcvr::Initialize(), and WsfEM_XmtrRcvr::ProcessInput().

◆ LoadReference()

bool WsfEM_AttenuationTypes::LoadReference ( UtInput & aInput,
WsfStringId & aTypeName )

Process a possible reference to a attenuation model type.

Parameters
aInput[input] The input stream.
aTypeName[output] The name of the referenced attenuation model type (valid only if the function return value is true).
Returns
true if the command was a reference to a attenuation model or false if not.

References WsfObjectTypeList< WsfEM_Attenuation >::Add().

◆ LoadType()

WsfEM_AttenuationTypes::LoadResult WsfEM_AttenuationTypes::LoadType ( UtInput & aInput)
overridevirtual

Process attenuation_model type input.

Parameters
aInputThe current input stream.
Returns
'true' if the current command was recognized and processed, 'false' if not recognized.

Reimplemented from WsfObjectTypeList< WsfEM_Attenuation >.

References WsfObjectTypeList< WsfEM_Attenuation >::Add().


The documentation for this class was generated from the following files:
Copyrights Multiple, All Rights Reserved