vin_connection_information.hpp
1 #pragma once
2 
3 #include "../global.hpp"
4 #include "../string.hpp"
5 
6 
7 #include "driver.hpp"
8 
9 namespace Cvb
10 {
11 
12 CVB_BEGIN_INLINE_NS
13 
14 namespace Driver
15 {
16 
18 
25 {
26  friend VinDevice;
27 
28  public:
29 
30  VinConnectionInformation() = default;
31 
33 
39  int CurrentPort() const noexcept
40  {
41  return currentPort_;
42  }
43 
45 
51  int CurrentBoard() const noexcept
52  {
53  return currentBoard_;
54  }
55 
57 
61  String AccessToken() const noexcept
62  {
63  return accessToken_;
64  }
65 
66  private:
67 
68 
69 
70  VinConnectionInformation(int currentPort, int currentBoard) noexcept
71  : currentPort_(currentPort)
72  , currentBoard_(currentBoard)
73  {
74  }
75 
76  VinConnectionInformation(const String accessToken) noexcept
77  : accessToken_(accessToken)
78  {
79  }
80 
81  int currentPort_ = -1;
82  int currentBoard_ = -1;
83  String accessToken_;
84 };
85 
86 
87 
88 
89 }
90 
91 using Driver::VinConnectionInformation;
92 
93 CVB_END_INLINE_NS
94 
95 }
int CurrentBoard() const noexcept
Gets the board number where the device is located.
Definition: vin_connection_information.hpp:51
A device representing a video interface driver (vin).
Definition: decl_vin_device.hpp:35
STL class.
Root namespace for the Image Manager interface.
Definition: version.hpp:11
Contains the board and port information of a device or its access token.
Definition: vin_connection_information.hpp:24
String AccessToken() const noexcept
Gets the device access token if available.
Definition: vin_connection_information.hpp:61
int CurrentPort() const noexcept
Gets the camera port number where the device is located.
Definition: vin_connection_information.hpp:39