VR-Exchange 2.4 API Documentation
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
tenaBroker/tenaBroker/entityTrans.h
Go to the documentation of this file.
1 /*****************************************************************************
2  * Copyright (c) 2015 VT MAK
3  * All rights reserved.
4  ****************************************************************************/
5 
9 
10 #pragma once
11 
12 #include <tenaBroker/tenaTrans.h>
13 #include <vlTena/entityPublisher.h>
15 #include <vl/entityStateRepository.h>
16 
17 #define ENTITY_TEMPLATE_ARGS \
18  DtPortalEntity, DtPortalReflectedEntity, \
19  DtReflectedEntity, DtReflectedEntityList, \
20  DtEntityStateRepository, DtEntityPublisher
21 
22 namespace MAKVrExchange
23 {
24 
25  namespace DtTenaBroker
26  {
27 
30  template <>
31  DT_DLL_TENABROKER DtEntityIdentifier
33  const DtPortalReflectedEntity* refObj, const DtString& identifier );
34 
37  template <>
38  DT_DLL_TENABROKER DtObjectPublisher*
40  const DtPortalReflectedEntity* refObj, const DtEntityIdentifier& name );
41 
42 
46  : public DtTenaObjectTranslator<ENTITY_TEMPLATE_ARGS>
47  {
48  public:
49 
51  Dt_DEF_TRANSLATOR_NAME( "Entity State" );
52 
54  DtEntityTranslator( DtBroker* broker );
55 
57  virtual ~DtEntityTranslator();
58 
59  protected:
60 
62  virtual bool isThrottlingRateOk( DtEntityPublisher* publisher,
63  DtBrokerObject* brokerObj );
64 
67  virtual bool isTenaPublishable( const DtBrokerObject* brokerObj,
68  const DtPortalReflectedEntity* refObj );
69 
71  virtual DtString tenaObjectName( const DtPortalReflectedEntity* refObj ) const;
72 
75  virtual void createTenaPublisher( DtBrokerObject* brokerObj );
76 
78  virtual void updateTenaBrokerObject( DtBrokerObject* brokerObj,
79  const DtEntityStateRepository& sr );
80 
82  virtual void updatePortalBrokerObject( DtBrokerObject* brokerObj,
83  const DtPortalEntity& sr );
84 
86  virtual void updateFilteredState( DtBrokerObject* brokerObj,
87  DtPortalEntityPublisher* publisher, DtReflectedEntity* refObj );
88 
90  virtual DtPortalEntity* translate( DtPortalEntity* destination,
91  const DtEntityStateRepository& source, const DtReflectedEntity& refObj );
92 
94  virtual void syncPortalDeadReckonedValues( DtPortalEntity& destination,
95  const DtEntityStateRepository& source );
96 
98  virtual DtEntityStateRepository* translate( DtEntityStateRepository* destination,
99  const DtPortalEntity& source, const DtPortalReflectedEntity& refObj );
100 
102  virtual void syncTenaDeadReckonedValues( DtEntityStateRepository& destination,
103  const DtPortalEntity& source );
104 
105  };
106 
107  }
108 }

Document ID: Generated on Thu Jul 23 10:25:22 EDT 2015 from SVN revision 155065
Copyright © 2005-2014 VT MÄK. All Rights Reserved (www.mak.com)