Safir SDK Core
Loading...
Searching...
No Matches
Safir::Dob::Typesystem Namespace Reference

This namespace contains the DOB Typesystem functionality and definitions. More...

Namespaces

namespace  Internal
 This namespace contains stuff that is internal to the DOB typesystem.
 
namespace  Members
 Functions for getting member information from types.
 
namespace  Operations
 Operations on DOB types.
 
namespace  Parameters
 Functions for getting parameter information from types.
 
namespace  Si32
 32 bit SI-types.
 
namespace  Si64
 64 bit SI-types.
 
namespace  ToolSupport
 
namespace  Utilities
 Utility functions for users of the DOB type system.
 

Classes

class  ArrayContainer
 STL container for arrays of DOB-containers. More...
 
class  BinaryContainer
 Container for Binary. More...
 
class  ChannelId
 Class containing the identity of a channel. More...
 
class  ConfigurationErrorException
 Used when there is an error that implies that there is something wrong in the configuration. More...
 
class  ContainerBase
 Base class for all Containers. More...
 
class  ContainerProxy
 
class  ContainerProxy< BinaryContainer >
 
class  ContainerProxy< ObjectContainerImpl< Object > >
 
class  ContainerProxy< ObjectContainerImpl< U > >
 
class  ContainerProxy< StringContainer >
 
class  DictionaryContainer
 Container class for dictionaries of key value pairs. More...
 
class  DictionaryContainerBase
 Base class for all dictionary containers. More...
 
class  EntityId
 Class containing the identity of an entity. More...
 
class  EnumerationContainerBase
 Base class for containers of enumeration values. More...
 
class  EnumerationSequenceContainer
 Container for sequences of enumeration values. More...
 
class  EnumerationSequenceContainerBase
 Base class for containers for sequences of enumeration values. More...
 
class  Exception
 This is the base class of all (non-Fundamental) Exceptions. More...
 
class  FundamentalException
 This is the base class of all Fundamental Exceptions. More...
 
class  GenericObjectSequenceContainer
 
class  GenericObjectSequenceContainerBase
 Base class for all object sequences. More...
 
class  HandlerId
 Class containing the identity of a handler. More...
 
class  IllegalValueException
 A parameter in the call was invalid. More...
 
class  IncompatibleTypesException
 This exception is thrown if a class cannot be cast to the expected type. More...
 
class  InstanceId
 Class containing the identity of an instance. More...
 
class  LibraryExceptions
 Contains methods used when passing exceptions across language boundaries. More...
 
class  NullException
 Thrown when an application attempts to get the value of a member that is null. More...
 
class  Object
 The base class for all DOB objects. More...
 
class  ObjectContainerBase
 Base class for all object containers. More...
 
class  ObjectContainerImpl
 Template class for all containers of automatically generated DOB objects. More...
 
class  ObjectContainerImpl< Object >
 This is a specialization of the ObjectContainerImpl template for the case where the template argument is Dob::Typesystem::Object. More...
 
class  ObjectFactory
 This class is an object factory for all automatically generated DOB classes. More...
 
class  Properties
 Functions for getting property information from types and objects. More...
 
class  ReadOnlyException
 Used when someone tries to set a property that is mapped to something that cannot be changed. More...
 
class  SequenceContainer
 Container class for sequences of values. More...
 
class  Serialization
 Functions for serializing objects to binary, XML and JSON forms. More...
 
class  SoftwareViolationException
 Meant to be used when something goes very wrong. More...
 
class  StringContainer
 Container for strings (std::wstring). More...
 
class  ValueContainer
 Container for base types. More...
 

Typedefs

typedef DotsC_TypeId TypeId
 A unique type identifier.
 
typedef std::vector< TypeIdTypeIdVector
 A vector of TypeIds.
 
typedef DotsC_EnumerationValue EnumerationValue
 The ordinal value of an enumeration.
 
typedef DotsC_MemberType MemberType
 An enumeration of all possible types of an object member.
 
typedef DotsC_PropertyMappingKind PropertyMappingKind
 An enumeration of the possible ways a property value can be defined.
 
typedef DotsC_CollectionType CollectionType
 An enumeration of all possible collection types of an object member.
 
typedef std::vector< char > BinarySerialization
 A type to contain binary serializations of DOB objects.
 
typedef std::vector< char > Binary
 A type to contain binary data.
 
typedef std::shared_ptr< ObjectObjectPtr
 A smart pointer to an Object.
 
typedef std::shared_ptr< const ObjectObjectConstPtr
 A smart pointer to a const Object.
 
typedef Safir::Dob::Typesystem::ObjectContainerImpl< ObjectObjectContainer
 Container for DOB Objects.
 
Container array typedefs
typedef ArrayContainer< BooleanContainerBooleanContainerArray
 An array of DOB-containers containing booleans.
 
typedef ArrayContainer< Int32ContainerInt32ContainerArray
 An array of DOB-containers containing 32 bit integers.
 
typedef ArrayContainer< Int64ContainerInt64ContainerArray
 An array of DOB-containers containing 64 bit integers.
 
typedef ArrayContainer< Float32ContainerFloat32ContainerArray
 An array of DOB-containers containing 32 bit floats.
 
typedef ArrayContainer< Float64ContainerFloat64ContainerArray
 An array of DOB-containers containing 64 bit floats.
 
typedef ArrayContainer< TypeIdContainerTypeIdContainerArray
 An array of DOB-containers containing TypeIds.
 
typedef ArrayContainer< InstanceIdContainerInstanceIdContainerArray
 An array of DOB-containers containing InstanceIds.
 
typedef ArrayContainer< EntityIdContainerEntityIdContainerArray
 An array of DOB-containers containing EntityIds.
 
typedef ArrayContainer< ChannelIdContainerChannelIdContainerArray
 An array of DOB-containers containing ChannelIds.
 
typedef ArrayContainer< HandlerIdContainerHandlerIdContainerArray
 An array of DOB-containers containing HandlerIds.
 
typedef ArrayContainer< StringContainerStringContainerArray
 An array of DOB-containers containing strings.
 
typedef Safir::Dob::Typesystem::ArrayContainer< ObjectContainerObjectContainerArray
 An array of DOB-containers containing DOB-objects.
 
typedef Safir::Dob::Typesystem::ArrayContainer< BinaryContainerBinaryContainerArray
 An array of DOB-containers containing Binaries.
 
Base Types

These are the types that all numeric types in the DOB are based on.

They are guaranteed to be of the correct size on all supported platforms.

typedef DotsC_Int32 Int32
 32 bit integer type.
 
typedef DotsC_Int64 Int64
 64 bit integer type.
 
typedef DotsC_Float32 Float32
 32 bit floating point type.
 
typedef DotsC_Float64 Float64
 64 bit floating point type.
 
Type indices.

Types for indices into types.

typedef DotsC_MemberIndex MemberIndex
 The index of a member in an object.
 
typedef DotsC_ArrayIndex ArrayIndex
 Index into an array.
 
typedef DotsC_ParameterIndex ParameterIndex
 The index of a parameter in an object.
 
Basic type container typedefs
typedef SequenceContainer< std::wstring > StringSequenceContainer
 A container containing string values.
 
typedef SequenceContainer< bool > BooleanSequenceContainer
 A container containing boolean values.
 
typedef SequenceContainer< Int32Int32SequenceContainer
 A container containing 32 bit integer values.
 
typedef SequenceContainer< Int64Int64SequenceContainer
 A container containing 64 bit integer values.
 
typedef SequenceContainer< Float32Float32SequenceContainer
 A container containing 32 bit floating point values.
 
typedef SequenceContainer< Float64Float64SequenceContainer
 A container containing 64 bit floating point values.
 
typedef SequenceContainer< TypeIdTypeIdSequenceContainer
 A container containing TypeId values.
 
typedef SequenceContainer< InstanceIdInstanceIdSequenceContainer
 A container containing InstanceId values.
 
typedef SequenceContainer< EntityIdEntityIdSequenceContainer
 A container containing EntityId values.
 
typedef SequenceContainer< ChannelIdChannelIdSequenceContainer
 A container containing ChannelId values.
 
typedef SequenceContainer< HandlerIdHandlerIdSequenceContainer
 A container containing HandlerId values.
 
typedef SequenceContainer< BinaryBinarySequenceContainer
 A container containing Binary values.
 
typedef GenericObjectSequenceContainer< ObjectObjectSequenceContainer
 A container containing Object values.
 
typedef ValueContainer< bool > BooleanContainer
 A container containing boolean values.
 
typedef ValueContainer< Int32Int32Container
 A container containing 32 bit integer values.
 
typedef ValueContainer< Int64Int64Container
 A container containing 64 bit integer values.
 
typedef ValueContainer< Float32Float32Container
 A container containing 32 bit floating point values.
 
typedef ValueContainer< Float64Float64Container
 A container containing 64 bit floating point values.
 
typedef ValueContainer< TypeIdTypeIdContainer
 A container containing TypeId values.
 
typedef ValueContainer< InstanceIdInstanceIdContainer
 A container containing InstanceId values.
 
typedef ValueContainer< EntityIdEntityIdContainer
 A container containing EntityId values.
 
typedef ValueContainer< ChannelIdChannelIdContainer
 A container containing ChannelId values.
 
typedef ValueContainer< HandlerIdHandlerIdContainer
 A container containing HandlerId values.
 

Functions

static std::wostream & operator<< (std::wostream &out, const ChannelId &channelId)
 
std::size_t hash_value (const Safir::Dob::Typesystem::ChannelId &val)
 
static bool IsChanged (const ContainerBase &container)
 Check if a container is changed.
 
static bool operator== (const ContainerProxy< ChannelIdContainer > &first, const ChannelId &second)
 
static bool operator!= (const ContainerProxy< ChannelIdContainer > &first, const ChannelId &second)
 
static bool operator== (const ContainerProxy< HandlerIdContainer > &first, const HandlerId &second)
 
static bool operator!= (const ContainerProxy< HandlerIdContainer > &first, const HandlerId &second)
 
static bool operator== (const ContainerProxy< InstanceIdContainer > &first, const InstanceId &second)
 
static bool operator!= (const ContainerProxy< InstanceIdContainer > &first, const InstanceId &second)
 
static bool operator== (const ContainerProxy< EntityIdContainer > &first, const EntityId &second)
 
static bool operator!= (const ContainerProxy< EntityIdContainer > &first, const EntityId &second)
 
static bool operator== (const std::wstring &first, const ContainerProxy< StringContainer > &second)
 
static bool operator!= (const std::wstring &first, const ContainerProxy< StringContainer > &second)
 
static bool operator== (const Binary &first, const ContainerProxy< BinaryContainer > &second)
 
static bool operator!= (const Binary &first, const ContainerProxy< BinaryContainer > &second)
 
static std::wostream & operator<< (std::wostream &out, const EntityId &entityId)
 
template<class T >
static void hash_combine (std::size_t &seed, const T &v)
 
std::size_t hash_value (const Safir::Dob::Typesystem::EntityId &eid)
 
static std::wostream & operator<< (std::wostream &out, const HandlerId &handlerId)
 
std::size_t hash_value (const Safir::Dob::Typesystem::HandlerId &val)
 
static std::wostream & operator<< (std::wostream &out, const InstanceId &instanceId)
 
std::size_t hash_value (const Safir::Dob::Typesystem::InstanceId &val)
 

Detailed Description

This namespace contains the DOB Typesystem functionality and definitions.

Typedef Documentation

◆ ArrayIndex

typedef DotsC_ArrayIndex Safir::Dob::Typesystem::ArrayIndex

Index into an array.

DOB-object arrays are indexed using this type. Note: Even though this is a signed 32 bit integer only the positive values are valid.

See also
Dob::Typesystem::Members

◆ Binary

typedef std::vector<char> Safir::Dob::Typesystem::Binary

A type to contain binary data.

◆ BinaryContainerArray

◆ BinarySequenceContainer

A container containing Binary values.

◆ BinarySerialization

A type to contain binary serializations of DOB objects.

Note: If you need to get hold of a "raw" C-pointer to the data * use &binary[0]. See Effective STL Item 16 for more info.

◆ BooleanContainer

A container containing boolean values.

◆ BooleanContainerArray

An array of DOB-containers containing booleans.

◆ BooleanSequenceContainer

A container containing boolean values.

◆ ChannelIdContainer

◆ ChannelIdContainerArray

An array of DOB-containers containing ChannelIds.

◆ ChannelIdSequenceContainer

◆ CollectionType

typedef DotsC_CollectionType Safir::Dob::Typesystem::CollectionType

An enumeration of all possible collection types of an object member.

The values of this enumeration is defined in the file Safir/Dob/Typesystem/LanguageInterfaceDefs.h.

See also
Safir/Dob/Typesystem/LanguageInterfaceDefs.h

◆ EntityIdContainer

◆ EntityIdContainerArray

An array of DOB-containers containing EntityIds.

◆ EntityIdSequenceContainer

◆ EnumerationValue

typedef DotsC_EnumerationValue Safir::Dob::Typesystem::EnumerationValue

The ordinal value of an enumeration.

When you use the set or get the ordinal on an EnumerationContainer you will get values of this kind. Normally you will not need to use this, instead use the real enumeration values through GetVal() and SetVal(). Note: Even though this is a signed 32 bit integer only the positive values are valid.

See also
Dob::Typesystem::EnumerationContainerBase::GetOrdinal
Dob::Typesystem::EnumerationContainerBase::SetOrdinal

◆ Float32

typedef DotsC_Float32 Safir::Dob::Typesystem::Float32

32 bit floating point type.

This type is guaranteed to be 32 bits on all platforms.

◆ Float32Container

A container containing 32 bit floating point values.

◆ Float32ContainerArray

An array of DOB-containers containing 32 bit floats.

◆ Float32SequenceContainer

A container containing 32 bit floating point values.

◆ Float64

typedef DotsC_Float64 Safir::Dob::Typesystem::Float64

64 bit floating point type.

This type is guaranteed to be 64 bits on all platforms.

◆ Float64Container

A container containing 64 bit floating point values.

◆ Float64ContainerArray

An array of DOB-containers containing 64 bit floats.

◆ Float64SequenceContainer

A container containing 64 bit floating point values.

◆ HandlerIdContainer

◆ HandlerIdContainerArray

An array of DOB-containers containing HandlerIds.

◆ HandlerIdSequenceContainer

◆ InstanceIdContainer

◆ InstanceIdContainerArray

An array of DOB-containers containing InstanceIds.

◆ InstanceIdSequenceContainer

◆ Int32

typedef DotsC_Int32 Safir::Dob::Typesystem::Int32

32 bit integer type.

This type is guaranteed to be 32 bits on all platforms.

◆ Int32Container

A container containing 32 bit integer values.

◆ Int32ContainerArray

An array of DOB-containers containing 32 bit integers.

◆ Int32SequenceContainer

A container containing 32 bit integer values.

◆ Int64

typedef DotsC_Int64 Safir::Dob::Typesystem::Int64

64 bit integer type.

This type is guaranteed to be 64 bits on all platforms.

◆ Int64Container

A container containing 64 bit integer values.

◆ Int64ContainerArray

An array of DOB-containers containing 64 bit integers.

◆ Int64SequenceContainer

A container containing 64 bit integer values.

◆ MemberIndex

typedef DotsC_MemberIndex Safir::Dob::Typesystem::MemberIndex

The index of a member in an object.

Members in objects are ordered according to the order they appear in the dou-file. However, do not rely on this, but use the Member-operations to get hold of indices if you need them. Note: Even though this is a signed 32 bit integer only the positive values are valid.

See also
Dob::Typesystem::Members

◆ MemberType

typedef DotsC_MemberType Safir::Dob::Typesystem::MemberType

An enumeration of all possible types of an object member.

The values of this enumeration is defined in the file Safir/Dob/Typesystem/LanguageInterfaceDefs.h.

See also
Safir/Dob/Typesystem/LanguageInterfaceDefs.h

◆ ObjectConstPtr

typedef std::shared_ptr< const Object > Safir::Dob::Typesystem::ObjectConstPtr

A smart pointer to a const Object.

◆ ObjectContainer

Container for DOB Objects.

This typedef defines an ObjectContainer that contains an Object... (This is also the reason that the object container template is called ObjectContainerImpl. The name ObjectContainer must be reserved for the container that contains the class Object... But there should be no need for you to worry about this...)

◆ ObjectContainerArray

◆ ObjectPtr

typedef std::shared_ptr< Object > Safir::Dob::Typesystem::ObjectPtr

A smart pointer to an Object.

◆ ObjectSequenceContainer

◆ ParameterIndex

typedef DotsC_ParameterIndex Safir::Dob::Typesystem::ParameterIndex

The index of a parameter in an object.

Parameters in objects are ordered according to the order they appear in the dou-file. However, do not rely on this, but use the Parameter-operations to get hold of indices if you need them. Note: Even though this is a signed 32 bit integer only the positive values are valid.

See also
Dob::Typesystem::Parameters

◆ PropertyMappingKind

typedef DotsC_PropertyMappingKind Safir::Dob::Typesystem::PropertyMappingKind

An enumeration of the possible ways a property value can be defined.

A property value can be either mapped to a class member or mapped to a parameter, or it can be null.

◆ StringContainerArray

An array of DOB-containers containing strings.

◆ StringSequenceContainer

A container containing string values.

◆ TypeId

typedef DotsC_TypeId Safir::Dob::Typesystem::TypeId

A unique type identifier.

A 64 bit integer that uniquely identifies a Dob type. This is in fact 64 bits of an MD5 of the type name and its namespace.

◆ TypeIdContainer

A container containing TypeId values.

◆ TypeIdContainerArray

An array of DOB-containers containing TypeIds.

◆ TypeIdSequenceContainer

A container containing TypeId values.

◆ TypeIdVector

A vector of TypeIds.

Function Documentation

◆ hash_combine()

template<class T >
static void Safir::Dob::Typesystem::hash_combine ( std::size_t & seed,
const T & v )
static

Referenced by hash_value().

Here is the caller graph for this function:

◆ hash_value() [1/4]

std::size_t Safir::Dob::Typesystem::hash_value ( const Safir::Dob::Typesystem::ChannelId & val)

References Safir::Dob::Typesystem::ChannelId::GetRawValue().

Here is the call graph for this function:

◆ hash_value() [2/4]

std::size_t Safir::Dob::Typesystem::hash_value ( const Safir::Dob::Typesystem::EntityId & eid)

References Safir::Dob::Typesystem::EntityId::GetInstanceId(), Safir::Dob::Typesystem::InstanceId::GetRawValue(), Safir::Dob::Typesystem::EntityId::GetTypeId(), and hash_combine().

Here is the call graph for this function:

◆ hash_value() [3/4]

std::size_t Safir::Dob::Typesystem::hash_value ( const Safir::Dob::Typesystem::HandlerId & val)

References Safir::Dob::Typesystem::HandlerId::GetRawValue().

Here is the call graph for this function:

◆ hash_value() [4/4]

std::size_t Safir::Dob::Typesystem::hash_value ( const Safir::Dob::Typesystem::InstanceId & val)

References Safir::Dob::Typesystem::InstanceId::GetRawValue().

Here is the call graph for this function:

◆ IsChanged()

static bool Safir::Dob::Typesystem::IsChanged ( const ContainerBase & container)
static

Check if a container is changed.

This meant for use with stuff in std::algorithms. All it does is call IsChanged on the container.

Parameters
container[in] - The container to check.
Returns
True if the container has changed.

References Safir::Dob::Typesystem::ContainerBase::IsChanged().

Referenced by Safir::Dob::Typesystem::ArrayContainer< T >::IsChanged().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ operator!=() [1/6]

static bool Safir::Dob::Typesystem::operator!= ( const Binary & first,
const ContainerProxy< BinaryContainer > & second )
static

References Safir::Dob::Typesystem::ContainerProxy< T >::GetVal().

Here is the call graph for this function:

◆ operator!=() [2/6]

static bool Safir::Dob::Typesystem::operator!= ( const ContainerProxy< ChannelIdContainer > & first,
const ChannelId & second )
static

References Safir::Dob::Typesystem::ContainerProxy< T >::GetVal().

Here is the call graph for this function:

◆ operator!=() [3/6]

static bool Safir::Dob::Typesystem::operator!= ( const ContainerProxy< EntityIdContainer > & first,
const EntityId & second )
static

References Safir::Dob::Typesystem::ContainerProxy< T >::GetVal().

Here is the call graph for this function:

◆ operator!=() [4/6]

static bool Safir::Dob::Typesystem::operator!= ( const ContainerProxy< HandlerIdContainer > & first,
const HandlerId & second )
static

References Safir::Dob::Typesystem::ContainerProxy< T >::GetVal().

Here is the call graph for this function:

◆ operator!=() [5/6]

static bool Safir::Dob::Typesystem::operator!= ( const ContainerProxy< InstanceIdContainer > & first,
const InstanceId & second )
static

References Safir::Dob::Typesystem::ContainerProxy< T >::GetVal().

Here is the call graph for this function:

◆ operator!=() [6/6]

static bool Safir::Dob::Typesystem::operator!= ( const std::wstring & first,
const ContainerProxy< StringContainer > & second )
static

References Safir::Dob::Typesystem::ContainerProxy< T >::GetVal().

Here is the call graph for this function:

◆ operator<<() [1/4]

static std::wostream & Safir::Dob::Typesystem::operator<< ( std::wostream & out,
const ChannelId & channelId )
static

References Safir::Dob::Typesystem::ChannelId::ToString().

Here is the call graph for this function:

◆ operator<<() [2/4]

static std::wostream & Safir::Dob::Typesystem::operator<< ( std::wostream & out,
const EntityId & entityId )
static

References Safir::Dob::Typesystem::EntityId::ToString().

Here is the call graph for this function:

◆ operator<<() [3/4]

static std::wostream & Safir::Dob::Typesystem::operator<< ( std::wostream & out,
const HandlerId & handlerId )
static

References Safir::Dob::Typesystem::HandlerId::ToString().

Here is the call graph for this function:

◆ operator<<() [4/4]

static std::wostream & Safir::Dob::Typesystem::operator<< ( std::wostream & out,
const InstanceId & instanceId )
static

References Safir::Dob::Typesystem::InstanceId::ToString().

Here is the call graph for this function:

◆ operator==() [1/6]

static bool Safir::Dob::Typesystem::operator== ( const Binary & first,
const ContainerProxy< BinaryContainer > & second )
static

References Safir::Dob::Typesystem::ContainerProxy< T >::GetVal().

Here is the call graph for this function:

◆ operator==() [2/6]

static bool Safir::Dob::Typesystem::operator== ( const ContainerProxy< ChannelIdContainer > & first,
const ChannelId & second )
static

References Safir::Dob::Typesystem::ContainerProxy< T >::GetVal().

Here is the call graph for this function:

◆ operator==() [3/6]

static bool Safir::Dob::Typesystem::operator== ( const ContainerProxy< EntityIdContainer > & first,
const EntityId & second )
static

References Safir::Dob::Typesystem::ContainerProxy< T >::GetVal().

Here is the call graph for this function:

◆ operator==() [4/6]

static bool Safir::Dob::Typesystem::operator== ( const ContainerProxy< HandlerIdContainer > & first,
const HandlerId & second )
static

References Safir::Dob::Typesystem::ContainerProxy< T >::GetVal().

Here is the call graph for this function:

◆ operator==() [5/6]

static bool Safir::Dob::Typesystem::operator== ( const ContainerProxy< InstanceIdContainer > & first,
const InstanceId & second )
static

References Safir::Dob::Typesystem::ContainerProxy< T >::GetVal().

Here is the call graph for this function:

◆ operator==() [6/6]

static bool Safir::Dob::Typesystem::operator== ( const std::wstring & first,
const ContainerProxy< StringContainer > & second )
static

References Safir::Dob::Typesystem::ContainerProxy< T >::GetVal().

Here is the call graph for this function: