Skip to content

Commit cd70fe2

Browse files
author
SDK Automation
committed
Generated from d7aec541537099657f4bd9c2f6ecf50347189c69
fixed prettier error
1 parent 86a15ae commit cd70fe2

File tree

7 files changed

+90
-12
lines changed

7 files changed

+90
-12
lines changed

sdk/features/arm-features/LICENSE.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
The MIT License (MIT)
22

3-
Copyright (c) 2019 Microsoft
3+
Copyright (c) 2020 Microsoft
44

55
Permission is hereby granted, free of charge, to any person obtaining a copy
66
of this software and associated documentation files (the "Software"), to deal

sdk/features/arm-features/README.md

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -19,8 +19,9 @@ npm install @azure/arm-features
1919

2020
##### Install @azure/ms-rest-nodeauth
2121

22+
- Please install minimum version of `"@azure/ms-rest-nodeauth": "^3.0.0"`.
2223
```bash
23-
npm install @azure/ms-rest-nodeauth
24+
npm install @azure/ms-rest-nodeauth@"^3.0.0"
2425
```
2526

2627
##### Sample code
@@ -95,4 +96,4 @@ See https://github.com/Azure/ms-rest-browserauth to learn how to authenticate to
9596

9697
- [Microsoft Azure SDK for Javascript](https://github.com/Azure/azure-sdk-for-js)
9798

98-
![Impressions](https://azure-sdk-impressions.azurewebsites.net/api/impressions/azure-sdk-for-js%2Fsdk%2Ffeatures%2Farm-features%2FREADME.png)
99+
![Impressions](https://azure-sdk-impressions.azurewebsites.net/api/impressions/azure-sdk-for-js/sdk/features/arm-features/README.png)

sdk/features/arm-features/package.json

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -4,9 +4,9 @@
44
"description": "FeatureClient Library with typescript type definitions for node.js and browser.",
55
"version": "1.0.3",
66
"dependencies": {
7-
"@azure/ms-rest-azure-js": "^1.3.2",
8-
"@azure/ms-rest-js": "^1.8.1",
9-
"tslib": "^1.9.3"
7+
"@azure/ms-rest-azure-js": "^2.0.1",
8+
"@azure/ms-rest-js": "^2.0.4",
9+
"tslib": "^1.10.0"
1010
},
1111
"keywords": [
1212
"node",
@@ -20,11 +20,11 @@
2020
"module": "./esm/featureClient.js",
2121
"types": "./esm/featureClient.d.ts",
2222
"devDependencies": {
23-
"typescript": "^3.1.1",
24-
"rollup": "^0.66.2",
25-
"rollup-plugin-node-resolve": "^3.4.0",
23+
"typescript": "^3.5.3",
24+
"rollup": "^1.18.0",
25+
"rollup-plugin-node-resolve": "^5.2.0",
2626
"rollup-plugin-sourcemaps": "^0.4.2",
27-
"uglify-js": "^3.4.9"
27+
"uglify-js": "^3.6.0"
2828
},
2929
"homepage": "https://github.com/Azure/azure-sdk-for-js/tree/master/sdk/features/arm-features",
3030
"repository": {

sdk/features/arm-features/rollup.config.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@ const config = {
2929
*/`
3030
},
3131
plugins: [
32-
nodeResolve({ module: true }),
32+
nodeResolve({ mainFields: ['module', 'main'] }),
3333
sourcemaps()
3434
]
3535
};

sdk/features/arm-features/src/models/index.ts

Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -227,6 +227,26 @@ export type FeaturesRegisterResponse = FeatureResult & {
227227
};
228228
};
229229

230+
/**
231+
* Contains response data for the unregister operation.
232+
*/
233+
export type FeaturesUnregisterResponse = FeatureResult & {
234+
/**
235+
* The underlying HTTP response.
236+
*/
237+
_response: msRest.HttpResponse & {
238+
/**
239+
* The response body as text (string format)
240+
*/
241+
bodyAsText: string;
242+
243+
/**
244+
* The response body as parsed JSON or XML
245+
*/
246+
parsedBody: FeatureResult;
247+
};
248+
};
249+
230250
/**
231251
* Contains response data for the listAllNext operation.
232252
*/

sdk/features/arm-features/src/operations/features.ts

Lines changed: 57 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -143,6 +143,38 @@ export class Features {
143143
callback) as Promise<Models.FeaturesRegisterResponse>;
144144
}
145145

146+
/**
147+
* Unregisters the preview feature for the subscription.
148+
* @param resourceProviderNamespace The namespace of the resource provider.
149+
* @param featureName The name of the feature to unregister.
150+
* @param [options] The optional parameters
151+
* @returns Promise<Models.FeaturesUnregisterResponse>
152+
*/
153+
unregister(resourceProviderNamespace: string, featureName: string, options?: msRest.RequestOptionsBase): Promise<Models.FeaturesUnregisterResponse>;
154+
/**
155+
* @param resourceProviderNamespace The namespace of the resource provider.
156+
* @param featureName The name of the feature to unregister.
157+
* @param callback The callback
158+
*/
159+
unregister(resourceProviderNamespace: string, featureName: string, callback: msRest.ServiceCallback<Models.FeatureResult>): void;
160+
/**
161+
* @param resourceProviderNamespace The namespace of the resource provider.
162+
* @param featureName The name of the feature to unregister.
163+
* @param options The optional parameters
164+
* @param callback The callback
165+
*/
166+
unregister(resourceProviderNamespace: string, featureName: string, options: msRest.RequestOptionsBase, callback: msRest.ServiceCallback<Models.FeatureResult>): void;
167+
unregister(resourceProviderNamespace: string, featureName: string, options?: msRest.RequestOptionsBase | msRest.ServiceCallback<Models.FeatureResult>, callback?: msRest.ServiceCallback<Models.FeatureResult>): Promise<Models.FeaturesUnregisterResponse> {
168+
return this.client.sendOperationRequest(
169+
{
170+
resourceProviderNamespace,
171+
featureName,
172+
options
173+
},
174+
unregisterOperationSpec,
175+
callback) as Promise<Models.FeaturesUnregisterResponse>;
176+
}
177+
146178
/**
147179
* Gets all the preview features that are available through AFEC for the subscription.
148180
* @param nextPageLink The NextLink from the previous successful call to List operation.
@@ -300,6 +332,31 @@ const registerOperationSpec: msRest.OperationSpec = {
300332
serializer
301333
};
302334

335+
const unregisterOperationSpec: msRest.OperationSpec = {
336+
httpMethod: "POST",
337+
path: "subscriptions/{subscriptionId}/providers/Microsoft.Features/providers/{resourceProviderNamespace}/features/{featureName}/unregister",
338+
urlParameters: [
339+
Parameters.resourceProviderNamespace,
340+
Parameters.featureName,
341+
Parameters.subscriptionId
342+
],
343+
queryParameters: [
344+
Parameters.apiVersion
345+
],
346+
headerParameters: [
347+
Parameters.acceptLanguage
348+
],
349+
responses: {
350+
200: {
351+
bodyMapper: Mappers.FeatureResult
352+
},
353+
default: {
354+
bodyMapper: Mappers.CloudError
355+
}
356+
},
357+
serializer
358+
};
359+
303360
const listAllNextOperationSpec: msRest.OperationSpec = {
304361
httpMethod: "GET",
305362
baseUrl: "https://management.azure.com",

sdk/features/arm-features/tsconfig.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@
99
"esModuleInterop": true,
1010
"allowSyntheticDefaultImports": true,
1111
"forceConsistentCasingInFileNames": true,
12-
"lib": ["es6"],
12+
"lib": ["es6", "dom"],
1313
"declaration": true,
1414
"outDir": "./esm",
1515
"importHelpers": true

0 commit comments

Comments
 (0)