VR-Exchange 2.7 API Documentation
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
pVrvSetSystemState.h
Go to the documentation of this file.
1 /****************************************************************************
2  * Copyright (c) 2016 VT MAK
3  * All rights reserved.
4  ****************************************************************************/
5 
9 
10 #pragma once
11 
12 #include <portal/dllExport.h>
13 #include <portal/pInteraction.h>
14 
16 #define DtDEC_ATTRIBUTE_CLEAR( T, N, n ) \
17  public: \
18  void set##N( const T& val ) { my##N = val; myb##N = true; } \
19  const T& n() const { return my##N; } \
20  const bool isset##N() const { return myb##N; } \
21  void clear##N() { myb##N = false; } \
22  T& n() { return my##N; } \
23  protected: \
24  T my##N; \
25  bool myb##N;
26 
27 namespace MAKVrExchange
28 {
29 
30  class DtPortalConnection;
31 
36  : public DtPortalInteraction
37  {
38  public:
39 
41  typedef void (*functionCallback_type) (
42  const DtPortalVrvSetSystemStateInteraction& interaction, void* userData );
43 
46 
49 
51  static void addCallback( DtPortalConnection* connection,
52  functionCallback_type callbackFunction, void* userData );
53 
55  static void removeCallback( DtPortalConnection* connection,
56  functionCallback_type callbackFunction, void* userData );
57 
60 
61  DtDEC_ATTRIBUTE( DtEntityIdentifier, Vantage, vantage );
62  DtDEC_ATTRIBUTE_CLEAR( bool, EntityLabels, entityLabels );
63  DtDEC_ATTRIBUTE_CLEAR( bool, TacticalGraphicsLabels, tacticalGraphicsLabels );
64  DtDEC_ATTRIBUTE_CLEAR( bool, HeightAboveTerrainLines, heightAboveTerrainLines );
65  DtDEC_ATTRIBUTE_CLEAR( bool, FireDetonateLines, fireDetonateLines );
66  DtDEC_ATTRIBUTE_CLEAR( bool, TacticalGraphics, tacticalGraphics );
67  DtDEC_ATTRIBUTE_CLEAR( bool, RadioCommunications, radioCommunications );
68  DtDEC_ATTRIBUTE_CLEAR( bool, VaporTrail, vaporTrail );
69  DtDEC_ATTRIBUTE_CLEAR( bool, Tracks, tracks );
70  DtDEC_ATTRIBUTE_CLEAR( bool, PlanarReflections, planarReflections );
71 
73 
75  public:
76 
78 
79  static DtPortalMessage* create();
80 
81  virtual unsigned int netSize() const;
82  virtual void writeSelfToBuffer( void* buffer, int bufferSize ) const;
83  virtual void readSelfFromBuffer( const void* buffer, int bufferSize );
84 
85  virtual std::ostream& printDataToStream( std::ostream& stream ) const;
86 
87  private:
88 
92 
94  bool operator == ( const DtPortalVrvSetSystemStateInteraction& ) const;
95 
97  bool operator != ( const DtPortalVrvSetSystemStateInteraction& ) const;
98 
99  };
100 
101 
103  {
105  }
106 
107 }
#define DT_DLL_LIBPORTAL
Definition: include/portal/dllExport.h:20
#define DtDEC_ATTRIBUTE(T, N, n)
A Macro to define an attribute; as well as make an accessor and mutator for that attribute.
Definition: addAttribute.h:49
#define DtDEC_ATTRIBUTE_CLEAR(T, N, n)
Redefine attribute macro. All attributes in this message are optional.
Definition: pVrvSetSystemState.h:16
The base class for all messages passed through the portal.
Definition: pMessage.h:65
Contains the DtPortalInteraction class declaration.
DtPortalInteractions are a special type of DtPortalMessages which are used to transmit simulation dat...
Definition: pInteraction.h:21
static const DtPortalMessageKind theKind
NOTE: DtDEC_ATTRIBUTE resets the access specifier to protected.
Definition: pVrvSetSystemState.h:77
Vrf Set Data Interaction class.
Definition: pVrvSetSystemState.h:35
static DtPortalMessage * create()
Definition: pVrvSetSystemState.h:102
Connects a broker to the Portal Data Exchange.
Definition: pConnection.h:49
DtPortalMessageKind
A List of message kinds distributed with the Portal.
Definition: pMessageKinds.h:23

Document ID: Generated on Mon Apr 19 15:55:22 EDT 2021 from SVN revision 227909
Copyright © 2005-2021 MAK Technologies. All Rights Reserved (www.mak.com)