VR-Link API Documentation for DIS
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
intDatatypeRep.h
Go to the documentation of this file.
1 /*******************************************************************************
2 ** Copyright (c) 1992-2025 MAK Technologies, Inc
3 ** All rights reserved.
4 *******************************************************************************/
7 #pragma once
8 
9 
10 
11 #include "numberDatatypeRep.h"
12 
13 #include <vlutil/vlString.h>
14 #ifdef DtUSE_UTILITIES_NAMESPACE
15 namespace DtUSE_UTILITIES_NAMESPACE
16 {
17 #endif
18 class DtNetU32;
22 {
23 public:
24 
26  DtIntDatatypeRep(bool useImplicitPadding, bool unsign = false);
27 
29  virtual ~DtIntDatatypeRep();
30 
33 
35  DtIntDatatypeRep& operator=(const DtIntDatatypeRep& rhs);
36 
38  virtual const char* datatype() const;
39 
41  virtual int intVal(const void*);
42 
44  virtual unsigned unsignedIntVal(const void*) const;
45 
47  virtual DtString stringRep(const void* ptr, int* size = 0) const;
48 
51  virtual double numberRep(const void* ptr, int* size = 0) const;
52 
54  virtual int sizeNeeded(const void* ptr) const;
55 
57  virtual void setUnsigned(bool);
58 
60  virtual std::vector<char> valueFromStringRep(const DtString& stringRep) const;
61 
63  virtual int byteAlignment() const { return 4; };
64 
65 public:
66 
71  static int intValFromBuffer(const void*);
72 
73 protected:
74 
76  const DtNetU32* netValPtr(const void* ptr, int* size=0) const;
77 
78 protected:
80 };
81 
82 
83 #ifdef DtUSE_UTILITIES_NAMESPACE
84 } // end of namespace DtUSE_UTILITIES_NAMESPACE
85 #endif
A type of datatype that can turn itself into a number (double) representation.
Definition: numberDatatypeRep.h:21
OMT Datatype of type Integer - in network format which means Big Endian representation.
Definition: intDatatypeRep.h:21
Contains the DtString class declaration.
Network-order unsigned 32-bit quantity.
Definition: vlNetTypes.h:99
#define DT_DLL_OMTREADER
Definition: omtReader.h:27
virtual int byteAlignment() const
The alignment size in bytes for this representation.
Definition: intDatatypeRep.h:63
bool myIsUnsigned
Definition: intDatatypeRep.h:79
Instances of DtString are used to represent strings.
Definition: vlString.h:36

Document ID: Generated on Thu Oct 16 00:12:25 EDT 2025 from SVN revision 280738
Copyright © 1992-2025 MAK Technologies. All Rights Reserved (www.mak.com)