你当前正在访问 Microsoft Azure Global Edition 技术文档网站。 如果需要访问由世纪互联运营的 Microsoft Azure 中国技术文档网站,请访问 https://docs.azure.cn。
ProvisioningServiceClient class
构造函数
Provisioning |
方法
构造函数详细信息
ProvisioningServiceClient(TransportConfig, RestApiClient)
new ProvisioningServiceClient(config: TransportConfig, restApiClient?: RestApiClient)
参数
- config
-
TransportConfig
- restApiClient
-
RestApiClient
方法详细信息
createEnrollmentGroupDeviceRegistrationStateQuery(QuerySpecification, string, number)
创建一个查询,该查询可用于为特定的 EnrollmentGroup 返回现有设备注册状态的页面。
function createEnrollmentGroupDeviceRegistrationStateQuery(querySpecification: QuerySpecification, enrollmentGroupId: string, pageSize?: number): Query
参数
- querySpecification
-
QuerySpecification
查询规范。
- enrollmentGroupId
-
string
提供查询范围的 EnrollmentGroup ID。
- pageSize
-
number
每页要返回的最大元素数。
返回
Query
createEnrollmentGroupQuery(QuerySpecification, number)
创建一个查询,该查询可用于返回现有注册组的页面。
function createEnrollmentGroupQuery(querySpecification: QuerySpecification, pageSize?: number): Query
参数
- querySpecification
-
QuerySpecification
查询规范。
- pageSize
-
number
每页要返回的最大元素数。
返回
Query
createIndividualEnrollmentQuery(QuerySpecification, number)
创建可用于返回现有注册页的查询。
function createIndividualEnrollmentQuery(querySpecification: QuerySpecification, pageSize?: number): Query
参数
- querySpecification
-
QuerySpecification
查询规范。
- pageSize
-
number
每页要返回的最大元素数。
返回
Query
createOrUpdateEnrollmentGroup(EnrollmentGroup)
function createOrUpdateEnrollmentGroup(enrollmentGroup: EnrollmentGroup): Promise<ResultWithHttpResponse<EnrollmentGroup>>
参数
- enrollmentGroup
-
EnrollmentGroup
返回
Promise<ResultWithHttpResponse<EnrollmentGroup>>
createOrUpdateEnrollmentGroup(EnrollmentGroup, HttpResponseCallback<EnrollmentGroup>)
创建或更新设备注册组。
function createOrUpdateEnrollmentGroup(enrollmentGroup: EnrollmentGroup, callback?: HttpResponseCallback<EnrollmentGroup>)
参数
- enrollmentGroup
-
EnrollmentGroup
设备注册组。
- callback
-
HttpResponseCallback<EnrollmentGroup>
在操作完成后调用。
createOrUpdateIndividualEnrollment(IndividualEnrollment)
function createOrUpdateIndividualEnrollment(enrollment: IndividualEnrollment): Promise<ResultWithHttpResponse<IndividualEnrollment>>
参数
- enrollment
-
IndividualEnrollment
返回
Promise<ResultWithHttpResponse<IndividualEnrollment>>
createOrUpdateIndividualEnrollment(IndividualEnrollment, HttpResponseCallback<IndividualEnrollment>)
创建或更新设备注册记录。
function createOrUpdateIndividualEnrollment(enrollment: IndividualEnrollment, callback?: HttpResponseCallback<IndividualEnrollment>)
参数
- enrollment
-
IndividualEnrollment
设备注册记录。
- callback
-
HttpResponseCallback<IndividualEnrollment>
在操作完成后调用。
deleteDeviceRegistrationState(string | DeviceRegistrationState)
function deleteDeviceRegistrationState(idOrRegistrationState: string | DeviceRegistrationState): Promise<void>
参数
- idOrRegistrationState
-
string | DeviceRegistrationState
返回
Promise<void>
deleteDeviceRegistrationState(string | DeviceRegistrationState, ErrorCallback)
function deleteDeviceRegistrationState(idOrRegistrationState: string | DeviceRegistrationState, deleteCallback: ErrorCallback)
参数
- idOrRegistrationState
-
string | DeviceRegistrationState
- deleteCallback
-
ErrorCallback
deleteDeviceRegistrationState(string | DeviceRegistrationState, string)
function deleteDeviceRegistrationState(idOrRegistrationState: string | DeviceRegistrationState, etag: string): Promise<void>
参数
- idOrRegistrationState
-
string | DeviceRegistrationState
- etag
-
string
返回
Promise<void>
deleteDeviceRegistrationState(string | DeviceRegistrationState, string, ErrorCallback)
删除设备注册状态。
function deleteDeviceRegistrationState(idOrRegistrationState: string | DeviceRegistrationState, etag: string, deleteCallback?: ErrorCallback)
参数
- idOrRegistrationState
-
string | DeviceRegistrationState
包含注册 ID 或实际 DeviceRegistrationState 的字符串。
- etag
-
string
- deleteCallback
-
ErrorCallback
在操作完成后调用。
deleteEnrollmentGroup(string | EnrollmentGroup)
function deleteEnrollmentGroup(enrollmentGroupOrId: string | EnrollmentGroup): Promise<void>
参数
- enrollmentGroupOrId
-
string | EnrollmentGroup
返回
Promise<void>
deleteEnrollmentGroup(string | EnrollmentGroup, ErrorCallback)
function deleteEnrollmentGroup(enrollmentGroupOrId: string | EnrollmentGroup, deleteCallback: ErrorCallback)
参数
- enrollmentGroupOrId
-
string | EnrollmentGroup
- deleteCallback
-
ErrorCallback
deleteEnrollmentGroup(string | EnrollmentGroup, string)
function deleteEnrollmentGroup(enrollmentGroupOrId: string | EnrollmentGroup, etag: string): Promise<void>
参数
- enrollmentGroupOrId
-
string | EnrollmentGroup
- etag
-
string
返回
Promise<void>
deleteEnrollmentGroup(string | EnrollmentGroup, string, ErrorCallback)
删除设备注册组。
function deleteEnrollmentGroup(enrollmentGroupOrId: string | EnrollmentGroup, etag: string, deleteCallback?: ErrorCallback)
参数
- enrollmentGroupOrId
-
string | EnrollmentGroup
EnrollmentGroup 对象或包含注册组 ID 的字符串。
- etag
-
string
- deleteCallback
-
ErrorCallback
在操作完成后调用。
deleteIndividualEnrollment(string | IndividualEnrollment)
function deleteIndividualEnrollment(enrollmentOrId: string | IndividualEnrollment): Promise<void>
参数
- enrollmentOrId
-
string | IndividualEnrollment
返回
Promise<void>
deleteIndividualEnrollment(string | IndividualEnrollment, ErrorCallback)
function deleteIndividualEnrollment(enrollmentOrId: string | IndividualEnrollment, deleteCallback: ErrorCallback)
参数
- enrollmentOrId
-
string | IndividualEnrollment
- deleteCallback
-
ErrorCallback
deleteIndividualEnrollment(string | IndividualEnrollment, string)
function deleteIndividualEnrollment(enrollmentOrId: string | IndividualEnrollment, etag: string): Promise<void>
参数
- enrollmentOrId
-
string | IndividualEnrollment
- etag
-
string
返回
Promise<void>
deleteIndividualEnrollment(string | IndividualEnrollment, string, ErrorCallback)
删除设备注册记录。
function deleteIndividualEnrollment(enrollmentOrId: string | IndividualEnrollment, etag: string, deleteCallback?: ErrorCallback)
参数
- enrollmentOrId
-
string | IndividualEnrollment
一个 IndividualEnrollment 对象或包含注册 ID 的字符串。
- etag
-
string
- deleteCallback
-
ErrorCallback
在操作完成后调用。
fromConnectionString(string)
使用默认传输 (Http) 从给定连接字符串构造 ProvisioningServiceClient 对象。
static function fromConnectionString(value: string): ProvisioningServiceClient
参数
- value
-
string
一个连接字符串,用于封装) ProvisioningServiceClient 权限的相应 (读取和/或写入。
返回
fromTokenCredential(string, TokenCredential)
使用默认传输 (Http) 从给定的 Azure TokenCredential 构造 ProvisioningServiceClient 对象。
static function fromTokenCredential(hostName: string, tokenCredential: TokenCredential): ProvisioningServiceClient
参数
- hostName
-
string
Azure 服务的主机名。
- tokenCredential
- TokenCredential
用于通过 Azure 服务进行身份验证的 Azure TokenCredential
返回
getDeviceRegistrationState(string)
function getDeviceRegistrationState(id: string): Promise<ResultWithHttpResponse<DeviceRegistrationState>>
参数
- id
-
string
返回
Promise<ResultWithHttpResponse<DeviceRegistrationState>>
getDeviceRegistrationState(string, HttpResponseCallback<DeviceRegistrationState>)
获取设备注册状态。
function getDeviceRegistrationState(id: string, callback?: HttpResponseCallback<DeviceRegistrationState>)
参数
- id
-
string
注册 ID。
- callback
-
HttpResponseCallback<DeviceRegistrationState>
在操作完成后调用。
getEnrollmentGroup(string)
function getEnrollmentGroup(id: string): Promise<ResultWithHttpResponse<EnrollmentGroup>>
参数
- id
-
string
返回
Promise<ResultWithHttpResponse<EnrollmentGroup>>
getEnrollmentGroup(string, HttpResponseCallback<EnrollmentGroup>)
获取设备注册组。
function getEnrollmentGroup(id: string, getCallback?: HttpResponseCallback<EnrollmentGroup>)
参数
- id
-
string
IndividualEnrollment 组 ID。
- getCallback
-
HttpResponseCallback<EnrollmentGroup>
在操作完成后调用。
getEnrollmentGroupAttestationMechanism(string)
function getEnrollmentGroupAttestationMechanism(enrollmentGroupId: string): Promise<ResultWithHttpResponse<AttestationMechanism>>
参数
- enrollmentGroupId
-
string
返回
Promise<ResultWithHttpResponse<AttestationMechanism>>
getEnrollmentGroupAttestationMechanism(string, HttpResponseCallback<AttestationMechanism>)
获取 EnrollmentGroup 记录的证明机制。
function getEnrollmentGroupAttestationMechanism(enrollmentGroupId: string, callback: HttpResponseCallback<AttestationMechanism>)
参数
- enrollmentGroupId
-
string
EnrollmentGroup 的唯一标识符。
- callback
-
HttpResponseCallback<AttestationMechanism>
请求完成时调用的函数(出现错误或证明机械对象)。
getIndividualEnrollment(string)
function getIndividualEnrollment(id: string): Promise<ResultWithHttpResponse<IndividualEnrollment>>
参数
- id
-
string
返回
Promise<ResultWithHttpResponse<IndividualEnrollment>>
getIndividualEnrollment(string, HttpResponseCallback<IndividualEnrollment>)
获取设备注册记录。
function getIndividualEnrollment(id: string, getCallback?: HttpResponseCallback<IndividualEnrollment>)
参数
- id
-
string
注册 ID。
- getCallback
-
HttpResponseCallback<IndividualEnrollment>
在操作完成后调用。
getIndividualEnrollmentAttestationMechanism(string)
function getIndividualEnrollmentAttestationMechanism(enrollmentId: string): Promise<ResultWithHttpResponse<AttestationMechanism>>
参数
- enrollmentId
-
string
返回
Promise<ResultWithHttpResponse<AttestationMechanism>>
getIndividualEnrollmentAttestationMechanism(string, HttpResponseCallback<AttestationMechanism>)
获取 IndividualEnrollment 记录的证明机制。
function getIndividualEnrollmentAttestationMechanism(enrollmentId: string, callback: HttpResponseCallback<AttestationMechanism>)
参数
- enrollmentId
-
string
注册的唯一标识符。
- callback
-
HttpResponseCallback<AttestationMechanism>
请求完成时调用的函数(出现错误或证明机械对象)。
runBulkEnrollmentOperation(BulkEnrollmentOperation)
function runBulkEnrollmentOperation(bulkEnrollmentOperation: BulkEnrollmentOperation): Promise<ResultWithHttpResponse<BulkEnrollmentOperationResult>>
参数
- bulkEnrollmentOperation
-
BulkEnrollmentOperation
返回
Promise<ResultWithHttpResponse<BulkEnrollmentOperationResult>>
runBulkEnrollmentOperation(BulkEnrollmentOperation, HttpResponseCallback<BulkEnrollmentOperationResult>)
对注册记录数组运行多个 CRUD 操作。
function runBulkEnrollmentOperation(bulkEnrollmentOperation: BulkEnrollmentOperation, callback: HttpResponseCallback<BulkEnrollmentOperationResult>)
参数
- bulkEnrollmentOperation
-
BulkEnrollmentOperation
一个 对象,该对象指定对也是对象的一部分的 IndividualEnrollment 对象的数组的单一 CRUD 操作。
- callback
-
HttpResponseCallback<BulkEnrollmentOperationResult>
在操作完成后调用。