OSVR-Core
SyncDeviceToken.h
Go to the documentation of this file.
1 
11 // Copyright 2014 Sensics, Inc.
12 //
13 // Licensed under the Apache License, Version 2.0 (the "License");
14 // you may not use this file except in compliance with the License.
15 // You may obtain a copy of the License at
16 //
17 // http://www.apache.org/licenses/LICENSE-2.0
18 //
19 // Unless required by applicable law or agreed to in writing, software
20 // distributed under the License is distributed on an "AS IS" BASIS,
21 // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
22 // See the License for the specific language governing permissions and
23 // limitations under the License.
24 
25 #ifndef INCLUDED_SyncDeviceToken_h_GUID_0A738016_90A8_4E81_B5C0_247478D59FD2
26 #define INCLUDED_SyncDeviceToken_h_GUID_0A738016_90A8_4E81_B5C0_247478D59FD2
27 
28 // Internal Includes
30 
31 // Library/third-party includes
32 // - none
33 
34 // Standard includes
35 // - none
36 
37 namespace osvr {
38 namespace connection {
40  public:
41  SyncDeviceToken(std::string const &name);
42  virtual ~SyncDeviceToken();
43 
44  protected:
45  void m_setUpdateCallback(DeviceUpdateCallback const &cb) override;
46  void m_sendData(util::time::TimeValue const &timestamp,
47  MessageType *type, const char *bytestream,
48  size_t len) override;
49  util::GuardPtr m_getSendGuard() override;
50  void m_connectionInteract() override;
51 
52  private:
53  DeviceUpdateCallback m_cb;
54  };
55 } // namespace connection
56 } // namespace osvr
57 #endif // INCLUDED_SyncDeviceToken_h_GUID_0A738016_90A8_4E81_B5C0_247478D59FD2
A DeviceToken connects the generic device interaction code in PluginKit's C API with the workings of ...
Definition: DeviceToken.h:56
The main namespace for all C++ elements of the framework, internal and external.
Definition: namespace_osvr.dox:3
Base class for connection-specific message type registration.
Definition: MessageType.h:38
Definition: SyncDeviceToken.h:39
Standardized, portable parallel to struct timeval for representing both absolute times and time inter...
Definition: TimeValueC.h:81