Skip to content

Commit

Permalink
CodeGen from PR 14311 in Azure/azure-rest-api-specs
Browse files Browse the repository at this point in the history
Merge 0b016ccb70c70df04f6f0fc194626c805f393d29 into 99e258538f847ce188e754086c7a38864f26fab0
  • Loading branch information
SDKAuto committed May 13, 2021
1 parent ab552b1 commit 36050e9
Show file tree
Hide file tree
Showing 4 changed files with 39 additions and 9 deletions.
8 changes: 4 additions & 4 deletions sdk/iotcentral/arm-iotcentral/src/iotCentralClientContext.ts
Original file line number Diff line number Diff line change
Expand Up @@ -36,25 +36,25 @@ export class IotCentralClientContext extends msRestAzure.AzureServiceClient {
if (!options) {
options = {};
}
if (!options.userAgent) {
if(!options.userAgent) {
const defaultUserAgent = msRestAzure.getDefaultUserAgentValue();
options.userAgent = `${packageName}/${packageVersion} ${defaultUserAgent}`;
}

super(credentials, options);

this.apiVersion = '2018-09-01';
this.apiVersion = '2021-06-01';
this.acceptLanguage = 'en-US';
this.longRunningOperationRetryTimeout = 30;
this.baseUri = options.baseUri || this.baseUri || "https://management.azure.com";
this.requestContentType = "application/json; charset=utf-8";
this.credentials = credentials;
this.subscriptionId = subscriptionId;

if (options.acceptLanguage !== null && options.acceptLanguage !== undefined) {
if(options.acceptLanguage !== null && options.acceptLanguage !== undefined) {
this.acceptLanguage = options.acceptLanguage;
}
if (options.longRunningOperationRetryTimeout !== null && options.longRunningOperationRetryTimeout !== undefined) {
if(options.longRunningOperationRetryTimeout !== null && options.longRunningOperationRetryTimeout !== undefined) {
this.longRunningOperationRetryTimeout = options.longRunningOperationRetryTimeout;
}
}
Expand Down
24 changes: 21 additions & 3 deletions sdk/iotcentral/arm-iotcentral/src/models/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ export { BaseResource, CloudError };
*/
export interface AppSkuInfo {
/**
* The name of the SKU. Possible values include: 'F1', 'S1', 'ST0', 'ST1', 'ST2'
* The name of the SKU. Possible values include: 'F1', 'ST0', 'ST1', 'ST2'
*/
name: AppSku;
}
Expand Down Expand Up @@ -73,6 +73,11 @@ export interface App extends Resource {
* allows the application to be defined from scratch.
*/
template?: string;
/**
* The current state of the application. Possible values include: 'created', 'deleted',
* 'suspended'
*/
state?: AppState;
/**
* A valid instance SKU.
*/
Expand Down Expand Up @@ -110,6 +115,11 @@ export interface AppPatch {
* allows the application to be defined from scratch.
*/
template?: string;
/**
* The current state of the application. Possible values include: 'created', 'deleted',
* 'suspended'
*/
state?: AppState;
}

/**
Expand Down Expand Up @@ -330,13 +340,21 @@ export interface OperationListResult extends Array<Operation> {
nextLink?: string;
}

/**
* Defines values for AppState.
* Possible values include: 'created', 'deleted', 'suspended'
* @readonly
* @enum {string}
*/
export type AppState = 'created' | 'deleted' | 'suspended';

/**
* Defines values for AppSku.
* Possible values include: 'F1', 'S1', 'ST0', 'ST1', 'ST2'
* Possible values include: 'F1', 'ST0', 'ST1', 'ST2'
* @readonly
* @enum {string}
*/
export type AppSku = 'F1' | 'S1' | 'ST0' | 'ST1' | 'ST2';
export type AppSku = 'F1' | 'ST0' | 'ST1' | 'ST2';

/**
* Contains response data for the get operation.
Expand Down
12 changes: 12 additions & 0 deletions sdk/iotcentral/arm-iotcentral/src/models/mappers.ts
Original file line number Diff line number Diff line change
Expand Up @@ -113,6 +113,12 @@ export const App: msRest.CompositeMapper = {
name: "String"
}
},
state: {
serializedName: "properties.state",
type: {
name: "String"
}
},
sku: {
required: true,
serializedName: "sku",
Expand Down Expand Up @@ -173,6 +179,12 @@ export const AppPatch: msRest.CompositeMapper = {
type: {
name: "String"
}
},
state: {
serializedName: "properties.state",
type: {
name: "String"
}
}
}
}
Expand Down
4 changes: 2 additions & 2 deletions sdk/iotcentral/arm-iotcentral/src/operations/operations.ts
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ export class Operations {
}

/**
* Lists all of the available IoT Central application REST API operations.
* Lists all of the available IoT Central Resource Provider operations.
* @param [options] The optional parameters
* @returns Promise<Models.OperationsListResponse>
*/
Expand All @@ -50,7 +50,7 @@ export class Operations {
}

/**
* Lists all of the available IoT Central application REST API operations.
* Lists all of the available IoT Central Resource Provider operations.
* @param nextPageLink The NextLink from the previous successful call to List operation.
* @param [options] The optional parameters
* @returns Promise<Models.OperationsListNextResponse>
Expand Down

0 comments on commit 36050e9

Please sign in to comment.