7 #include "Arp/System/Core/Enum.hxx" 8 #include "Arp/System/Core/TypeDeduction.hxx" 12 namespace Arp {
namespace System {
namespace Security
17 namespace Arp {
namespace System {
namespace Rsc {
namespace Services
133 , ElementType(elementType)
134 , Dimensions(dimensions)
135 , FieldCount(fieldCount)
146 size_t Dimensions = 1;
156 size_t FieldCount = 0;
169 size_t FieldCount = 0;
174 template<class T, bool isSerializable = std::is_base_of<IRscSerializable, T>::value>
177 size_t FieldCount = 0;
181 struct StructInfo<T, true>
183 size_t FieldCount = T::GetFieldCount();
187 inline constexpr
RscType GetRscType(
void)
190 return std::is_enum<T>::value ? GetRscType<typename underlying_enum_type<T>::type>() :
192 std::is_class<T>::value ? RscType::Struct :
200 inline constexpr
RscType GetRscType<boolean>(void)
202 return RscType::Bool;
206 inline constexpr
RscType GetRscType<char8>(void)
208 return RscType::Uint8;
212 inline constexpr
RscType GetRscType<uint8>(void)
214 return RscType::Uint8;
218 inline constexpr
RscType GetRscType<int8>(void)
220 return RscType::Int8;
224 inline constexpr
RscType GetRscType<uint16>(void)
226 return RscType::Uint16;
230 inline constexpr
RscType GetRscType<int16>(void)
232 return RscType::Int16;
236 inline constexpr
RscType GetRscType<uint32>(void)
238 return RscType::Uint32;
242 inline constexpr
RscType GetRscType<int32>(void)
244 return RscType::Int32;
248 inline constexpr
RscType GetRscType<uint64>(void)
250 return RscType::Uint64;
254 inline constexpr
RscType GetRscType<int64>(void)
256 return RscType::Int64;
260 inline constexpr
RscType GetRscType<float32>(void)
262 return RscType::Real32;
266 inline constexpr
RscType GetRscType<float64>(void)
268 return RscType::Real64;
272 inline constexpr
RscType GetRscType<char*>(void)
274 return RscType::Utf8String;
284 inline constexpr
RscType GetRscType<String>(void)
286 return RscType::Utf8String;
290 inline constexpr
RscType GetRscType<DateTime>(void)
296 inline constexpr
RscType GetRscType<RscVersion>(void)
302 inline constexpr
RscType GetRscType<RscGuid>(void)
304 return RscType::Guid;
308 inline constexpr
RscType GetRscType<SecurityToken>(void)
314 inline constexpr
RscType GetRscTypeFrom(
const T& )
316 return GetRscType<T>();
320 inline constexpr
RscType GetRscTypeFrom(
const char(&)[N])
322 return RscType::Utf8String;
328 return RscType::Utf8String;
340 return RscType::Utf8String;
358 return RscType::Guid;
367 inline constexpr
bool IsPrimitiveRscType(
RscType type)
369 return (type >= RscType::Bool && type <= RscType::Real64) || (type >= RscType::IecTime && type <= RscType::IecTimeOfDay64);
374 os << Enum<RscType>(rhs);
Definition: RscGuid.hpp:17
32 bit floating point number
Definition: SecurityToken.hpp:11
Utf-16 string, not implemented in Rsc context
std::ostream & operator<<(std::ostream &os, const BasicString< CharType, Alloc > &right)
Streams the right string to the outstream os .
Definition: BasicString.hxx:1559
The class contains date and time informations.
Definition: DateTime.hpp:44
Definition: BasicFormatter.hxx:18
String for security context, handled by Rsc with SecureString
Adapter class for enums to make them loggable and parsable from e.g. XML files.
Definition: Enum.hxx:23
RscType
Datatypes supported by Rsc. Values are identical with CommonRemoting::RemotingMarshalType. Only supported types of RemotingMarshalType are included.
Definition: RscType.hpp:35
This class represents the version of a special SDK or Arp build.
Definition: BasicVersion.hpp:34
Object type handled by Rsc as RscVariant
Specifies a version with 4 version numbers and is marshalled to .NET type System.Version.
Definition: RscVersion.hpp:20
Security token needed for security services, handly by Rsc with SecurityToken
64 bit floating point number
Marshalls structure or class data types. Serialize and Deserialize have to marshal fields in the same...
Definition: IRscSerializable.hpp:18
Ansi string, not implemented in Rsc context
Specialized version of RscString for security context. Not implemented in this version. Wraps only RscString
Definition: RscType.hpp:27
std::uint8_t uint8
The Arp unsigned integer type of 1 byte size.
Definition: PrimitiveTypes.hpp:27
Root namespace for the PLCnext API
Datetime, handled by Rsc with DateTime
System components used by the System, Device, Plc or Io domains.
Stream type to marshal large data packets (see <see cref="RscStream")/>
This is the base class of all Arp exception classes.
Definition: Exception.hpp:15
Contains a static string with string lentgh up to N characters. The string has to be null terminated...
Definition: RscString.hxx:18
This class defines a base class for all enumerator implementations and some predefined enumerators as...
Definition: Enumerator.hxx:21