| Visioscan Set SDK Libraries 1.3.5 Visioscan Set SDK Help documentation file for C++ and C++/CLI |

Loading...
Searching...
No Matches
WSoftwareVersion.h
1#pragma once
2#include <SoftwareVersion.h>
3
4
5 using namespace WEnumerations;
6
7 namespace WUtils {
11 public ref class WSoftwareVersion
12 {
13 public:
14 WSoftwareVersion() {
15 _softVer = new SoftwareVersion();
16 }
17
18 WSoftwareVersion(WSoftwareVersion^ toCopy) {
19 _softVer = new SoftwareVersion();
20 Version = toCopy->Version;
21 Revision = toCopy->Revision;
22 Prototype = toCopy->Prototype;
23 HardwareVersion = toCopy->HardwareVersion;
24 CanNumber = toCopy->CanNumber;
25 PartNumber = toCopy->PartNumber;
26 }
27
28 ~WSoftwareVersion() {
29 delete(_softVer);
30 }
31
32 property int Version {
33 int get() {
34 return _softVer->GetVersion();
35 }
36 void set(int x) {
37 _softVer->SetVersion(x);
38 }
39 }
40 property int Revision {
41 int get() {
42 return _softVer->GetRevision();
43 }
44 void set(int x) {
45 _softVer->SetRevision(x);
46 }
47 }
48 property int Prototype {
49 int get() {
50 return _softVer->GetPrototype();
51 }
52 void set(int x) {
53 _softVer->SetPrototype(x);
54 }
55 }
56
57 property unsigned long CanNumber {
58 unsigned long get() {
59 return _softVer->GetCanNumber();
60 }
61 void set(unsigned long x) {
62 _softVer->SetCanNumber(x);
63 }
64 }
65 property unsigned int HardwareVersion {
66 unsigned int get() {
67 return _softVer->GetHardwareVersion();
68 }
69 void set(unsigned int x) {
70 _softVer->SetHardwareVersion(x);
71 }
72 }
73
74 property long PartNumber {
75 long get() {
76 return _softVer->GetPartNumber();
77 }
78 void set(long x) {
79 _softVer->SetPartNumber(x);
80 }
81 }
82
83 property ProductIdentification ProductTypeIdentification {
84 ProductIdentification get() {
85 unsigned int productType = _softVer->GetProductIdentification();
86
87 switch (productType) {
88 case UNKNOWN_PRODUCT:
89 return ProductIdentification::Unknown;
90 case RAW_DATA:
91 return ProductIdentification::RawData;
92 case ANTI_COLLISION:
93 return ProductIdentification::AntiCollision;
94 case NAVIGATION:
95 return ProductIdentification::Navigation;
96 case ROD_120:
97 return ProductIdentification::Rod120;
98 case ROD_130:
99 return ProductIdentification::Rod130;
100 case ROD_300:
101 return ProductIdentification::Rod300;
102 case ROD_500:
103 return ProductIdentification::Rod500;
104 }
105 }
106 void set(ProductIdentification x) {
107 _softVer->SetProductIdentification(x.GetHashCode());
108 }
109 }
110
111 static bool operator== (WSoftwareVersion^ pComp1, WSoftwareVersion^ pComp2) {
112 if (System::Object::ReferenceEquals(pComp1, pComp2))
113 return true;
114
115 if (System::Object::ReferenceEquals(pComp1, nullptr) ||
116 System::Object::ReferenceEquals(pComp2, nullptr)) {
117 return false;
118 }
119 return pComp1->Version == pComp2->Version &&
120 pComp1->Revision == pComp2->Revision &&
121 pComp1->Prototype == pComp2->Prototype &&
122 pComp1->HardwareVersion == pComp2->HardwareVersion &&
123 pComp1->CanNumber == pComp2->CanNumber &&
124 pComp1->PartNumber == pComp2->PartNumber &&
125 pComp1->ProductTypeIdentification == pComp2->ProductTypeIdentification;
126 }
127
128 static bool operator!= (WSoftwareVersion^ pComp1, WSoftwareVersion^ pComp2) {
129 return !(pComp1 == pComp2);
130 }
131 private:
132 SoftwareVersion* _softVer;
133 };
134}
WUtils
Definition WAvailableResolution.h:7
WEnumerations
Definition WEnums.h:4
WEnumerations::ProductIdentification
ProductIdentification
Definition WEnums.h:5
SoftwareVersion
Helper to encapsulate the software version.
Definition SoftwareVersion.h:21
WUtils::WSoftwareVersion
A wrapper on the SoftwareVersion data encapsulation.
Definition WSoftwareVersion.h:12
WUtils::WSoftwareVersion::Version
property int Version
Definition WSoftwareVersion.h:32
WUtils::WSoftwareVersion::WSoftwareVersion
WSoftwareVersion()
Definition WSoftwareVersion.h:14
WUtils::WSoftwareVersion::WSoftwareVersion
WSoftwareVersion(WSoftwareVersion^ toCopy)
Definition WSoftwareVersion.h:18
WUtils::WSoftwareVersion::~WSoftwareVersion
~WSoftwareVersion()
Definition WSoftwareVersion.h:28