VR-Exchange 2.7 API Documentation
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
pVrfControl.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 
15 namespace MAKVrExchange
16 {
17 
18  class DtPortalConnection;
19 
23  : public DtPortalInteraction
24  {
25  public:
26 
27  static const int DtUnknownControlType = 0;
28  static const int DtPauseControlType = 1;
29  static const int DtRunControlType = 2;
30  static const int DtRunDurationControlType = 3;
31  static const int DtRunCompleteControlType = 4;
32  static const int DtRewindControlType = 5;
33  static const int DtStepControlType = 6;
34 
35  public:
36 
38  typedef void (*functionCallback_type) (
39  const DtPortalVrfControlInteraction& interaction, void* userData );
40 
43 
46 
48  static void addCallback( DtPortalConnection* connection,
49  functionCallback_type callbackFunction, void* userData );
50 
52  static void removeCallback( DtPortalConnection* connection,
53  functionCallback_type callbackFunction, void* userData );
54 
57 
58  DtDEC_ATTRIBUTE( DtString, ControlType, controlType );
59  DtDEC_ATTRIBUTE( DtFloat64, Time, time );
60 
62 
64  public:
65 
67 
68  static DtPortalMessage* create();
69 
70  virtual unsigned int netSize() const;
71  virtual void writeSelfToBuffer( void* buffer, int bufferSize ) const;
72  virtual void readSelfFromBuffer( const void* buffer, int bufferSize );
73 
74  virtual std::ostream& printDataToStream( std::ostream& stream ) const;
75 
76  private:
77 
80 
82  bool operator == ( const DtPortalVrfControlInteraction& ) const;
83 
85  bool operator != ( const DtPortalVrfControlInteraction& ) const;
86 
87  };
88 
89 
91  {
92  return new DtPortalVrfControlInteraction();
93  }
94 
95 }
#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
static DtPortalMessage * create()
Definition: pVrfControl.h:90
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: pVrfControl.h:66
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
Vrf Control Interaction class.
Definition: pVrfControl.h:22

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)