MAK Data Logger API Documentation for HLA
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
enum16DatatypeRep.h
Go to the documentation of this file.
1 /*******************************************************************************
2 ** Copyright (c) 1992-2010 VT MAK
3 ** All rights reserved.
4 *******************************************************************************/
7 #pragma once
8 
9 
10 
11 #include "enumDatatypeRep.h"
12 #include <vlutil/vlString.h>
13 class DtNetU16;
14 
15 // Data representation type for 16 bit enumerations
17 {
18 public:
19 
21  DtEnum16DatatypeRep(bool useImplicitPadding);
22 
24  virtual ~DtEnum16DatatypeRep();
25 
28 
31 
33  virtual const char* datatype() const;
34 
36  virtual unsigned int enumVal(const void*, int* size = 0) const;
37 
39  virtual DtString stringRep(const void* ptr, int* size = 0) const;
40 
42  virtual double numberRep(const void* ptr, int* size = 0) const;
43 
45  virtual std::vector<char> valueFromStringRep(const DtString& stringRep) const;
46 
48  virtual int byteAlignment() const { return 2; };
49 
50 protected:
51 
53  const DtNetU16* netValPtr(const void* ptr, int* size=0) const;
54 
55 };
56 
57 
58 
Definition: enum16DatatypeRep.h:16
virtual std::vector< char > valueFromStringRep(const DtString &stringRep) const =0
The reverse of string rep, given a character string, this returns an unformatted byte stream...
#define DT_DLL_OMTREADER
Definition: omtReader.h:23
DtEnumDatatypeRep & operator=(const DtEnumDatatypeRep &rhs)
Assignment Operator.
virtual double numberRep(const void *ptr, int *size=0) const =0
virtual const char * datatype() const =0
virtual int byteAlignment() const
The alignment size in bytes for this representation.
Definition: enum16DatatypeRep.h:48
virtual DtString stringRep(const void *ptr, int *size=0) const =0
Given a byte string, returns a character string in a format that is easily read by a person...
virtual unsigned int enumVal(const void *, int *size=0) const =0
return the numeric enumerator value
Definition: enumDatatypeRep.h:17

Document ID: Generated on Thu Jul 14 15:45:33 EDT 2022 from SVN revision 244827
Copyright © 2021 MAK Technologies. All Rights Reserved (www.mak.com)