VR-Forces Developer's Guide
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
exTDLMessage.h
Go to the documentation of this file.
1 /*******************************************************************************
2 ** Copyright (c) 2018 MAK Technologies, Inc.
3 ** All rights reserved.
4 *******************************************************************************/
5 
6 #pragma once
7 
8 
11 
12 #include <vrfmsgs/vrfTDLMessage.h>
14 #include <matrix/vlVector.h>
15 
19 
22 
26 {
28  {
29  }
30 
31  DtNetU32 myMessageLength;
32  DtNetVector64 myLocation;
33 };
34 
36 
38 {
39 public:
40 
43 
46 
49 
51  virtual ~ExampleTDLMessage() override;
52 
54  virtual int tdlMessageType() const override;
55 
56  virtual DtVrfTDLMessage * clone() const override;
57 
58  static DtVrfTDLMessage* creator();
59 
61  virtual void printDataToString(DtString& str) override;
62 
63  virtual int messageVersion() const override;
64 
68  virtual int fixedSize() const override;
69 
71  virtual int variableSize() const override;
72 
74  virtual void setMessage(const DtString&);
75  const DtString& message() const;
76 
78  virtual void setLocation(const DtVector&);
79  virtual const DtVector& location() const;
80 
81 protected:
83  virtual void setFixedToNet(char* buffer) override;
84 
86  virtual int setFixedFromNet(const char* buffer) override;
87 
90  virtual const char* setVariableFromNet(const char* buffer, const char* fixedBuffer, int messageVersion) override;
91 
93  virtual char* setVariableToNet(char* buffer) override;
94 
95 protected:
96  DtVector myTgtLocation;
98 };
const int DtVrfTDLContactMessageType
Definition: tdlMessageTypes.h:12
DtNetVector64 myLocation
Definition: exTDLMessage.h:32
virtual const char * setVariableFromNet(const char *buffer, const char *fixedBuffer, int messageVersion) override
Sets the variable portion into internal structures. Returns a pointer at the end of this variable suc...
virtual int setFixedFromNet(const char *buffer) override
Sets the fixed portion from the buffer into internal structures and variables.
virtual int tdlMessageType() const override
TDL Message type.
ExampleTDLMessageStruct()
Definition: exTDLMessage.h:27
virtual DtVrfTDLMessage * clone() const override
The variable portion is the string of the message itself.
Definition: exTDLMessage.h:37
static DtVrfTDLMessage * creator()
DtVector myTgtLocation
Definition: exTDLMessage.h:96
DtNetU32 myMessageLength
Definition: exTDLMessage.h:31
DtString myTgtMessage
Definition: exTDLMessage.h:97
This is the FIXED portion of the TDL message. There could be variable content based on some members s...
Definition: exTDLMessage.h:25
Contains the DtVrfTDLMessage class declaration.
Definition: vrfTDLMessage.h:28
const DtString & message() const
virtual void setLocation(const DtVector &)
Accessor for location of object.
virtual int messageVersion() const override
Definition: vrfTDLMessage.h:54
virtual int fixedSize() const override
Fixed size of this message. Do not need to call parent method if this as the fixed portion will conta...
virtual void printDataToString(DtString &str) override
Print message.
const ExampleTDLMessage & operator=(ExampleTDLMessage &orig)
assignment operator: shallow; assigns values only
ExampleTDLMessage()
default constructor
virtual const DtVector & location() const
virtual char * setVariableToNet(char *buffer) override
Sets the variable portion to the net.
virtual void setFixedToNet(char *buffer) override
Sets the fixed potion to the net. Must call parent method first.
virtual int variableSize() const override
Returns the variable data size. Size of all the Statuss.
virtual ~ExampleTDLMessage() override
destructor
virtual void setMessage(const DtString &)
Set message.
const int ExampleTDLMessageType
Contains the ExampleTDLMessage class declaration.
Definition: exTDLMessage.h:21

Document ID: Generated on Thu Oct 23 22:29:17 EDT 2025 from SVN revision 280951
Copyright © 2005-2024 MAK Technologies. All Rights Reserved (www.mak.com)