NX Open C++ 参考指南
2406 v1.1
载入中...
搜索中...
未找到
D:
Tan_NX2406C++
UGopenLib
NX2406
UGOPEN
NXOpen
LicenseManager.hxx
1
//--------------------------------------------------------------------------
2
// Copyright 2024 Siemens
3
//--------------------------------------------------------------------------
4
// C++接口的头文件,用于JA API
5
//--------------------------------------------------------------------------
6
//
7
// 源文件:
8
// LicenseManager.ja
9
//
10
// 生成工具:
11
// apiwrap
12
//
13
// 警告:
14
// 此文件由工具自动生成 - 请勿手动编辑
15
//
16
#pragma once
17
#include <NXOpen/NXDeprecation.hxx>
18
#include <vector>
19
#include <NXOpen/NXString.hxx>
20
#include <NXOpen/Callback.hxx>
21
#include <NXOpen/TaggedObject.hxx>
22
#include <NXOpen/libnxopencpp_exports.hxx>
23
#ifdef _MSC_VER
24
#pragma warning(push)
25
#pragma warning(disable:4996)
26
#endif
27
#ifdef __GNUC__
28
#pragma GCC diagnostic ignored "-Wdeprecated-declarations"
29
#endif
30
namespace
NXOpen
31
{
32
class
LicenseManager
;
33
class
Session
;
34
class
LicenseManagerImpl;
51
class
NXOPENCPPEXPORT
LicenseManager
52
{
55
public
:
56
struct
LicenseBundle
57
{
58
public
:
int
NumUsing
;
59
public
:
NXString
BundleName
;
60
public
: LicenseBundle() :
61
NumUsing
(),
62
BundleName
()
63
{
64
}
66
public
:
LicenseBundle
(
int
numUsingInitial ,
67
const
NXString
&bundleNameInitial ) :
68
NumUsing
(numUsingInitial),
69
BundleName
(bundleNameInitial)
70
{
71
}
72
};
73
private
:
LicenseManagerImpl
* m_licensemanager_impl;
74
private
:
NXOpen::Session
* m_owner;
76
public
:
explicit
LicenseManager
(
NXOpen::Session
*owner);
78
public
:
80
tag_t
Tag
()
const
;
81
public
:
~LicenseManager
();
85
public
:
void
Reserve
86
(
87
const
NXString
& license ,
88
const
NXString
& contextName
89
);
93
void
Reserve
94
(
95
const
char
* license ,
96
const
char
* contextName
97
);
101
public
:
void
Release
102
(
103
const
NXString
& license ,
104
const
NXString
& contextName
105
);
109
void
Release
110
(
111
const
char
* license ,
112
const
char
* contextName
113
);
117
public
:
void
ReleaseAll
118
(
119
const
NXString
& contextName
120
);
124
void
ReleaseAll
125
(
126
const
char
* contextName
127
);
131
public
: std::vector<NXString>
GetReservedLicenses
132
(
133
const
NXString
& contextName
134
);
138
std::vector<NXString>
GetReservedLicenses
139
(
140
const
char
* contextName
141
);
145
public
: std::vector<NXOpen::LicenseManager::LicenseBundle>
GetBundlesSelected
146
(
147
);
152
public
:
void
SetBundlesForUse
153
(
154
std::vector<NXString> & bundles
155
);
159
public
: std::vector<NXString>
GetBundlesUsed
160
(
161
);
165
public
: std::vector<NXString>
GetActiveLicensesInABundle
166
(
167
const
NXString
& bundleName
168
);
172
std::vector<NXString>
GetActiveLicensesInABundle
173
(
174
const
char
* bundleName
175
);
179
public
:
bool
CheckPresence
180
(
181
const
NXString
& licenseName
182
);
186
bool
CheckPresence
187
(
188
const
char
* licenseName
189
);
193
public
:
bool
IsCheckedOut
194
(
195
const
NXString
& license
196
);
200
bool
IsCheckedOut
201
(
202
const
char
* license
203
);
204
};
//lint !e1712 default constructor not defined for class
205
}
206
#ifdef _MSC_VER
207
#pragma warning(pop)
208
#endif
209
#ifdef __GNUC__
210
#ifndef NX_NO_GCC_DEPRECATION_WARNINGS
211
#pragma GCC diagnostic warning "-Wdeprecated-declarations"
212
#endif
213
#endif
214
#undef EXPORTLIBRARY