Родитель
dce6b50338
Коммит
d1ba3e9b8f
|
@ -628,6 +628,9 @@
|
|||
# PRLabel: %Mgmt
|
||||
sdk/desktopvirtualization/arm-desktopvirtualization @qiaozha @dw511214992
|
||||
|
||||
# PRLabel: %Mgmt
|
||||
sdk/orbital/arm-orbital @qiaozha @dw511214992
|
||||
|
||||
# PRLabel: %Monitor
|
||||
/sdk/monitor/ @hectorhdzg @applicationinsights-js-owners
|
||||
/sdk/monitor/monitor-query @KarishmaGhiya @maorleger
|
||||
|
|
|
@ -40,6 +40,7 @@ specifiers:
|
|||
'@rush-temp/arm-notificationhubs': file:./projects/arm-notificationhubs.tgz
|
||||
'@rush-temp/arm-operationalinsights': file:./projects/arm-operationalinsights.tgz
|
||||
'@rush-temp/arm-operations': file:./projects/arm-operations.tgz
|
||||
'@rush-temp/arm-orbital': file:./projects/arm-orbital.tgz
|
||||
'@rush-temp/arm-policy': file:./projects/arm-policy.tgz
|
||||
'@rush-temp/arm-postgresql': file:./projects/arm-postgresql.tgz
|
||||
'@rush-temp/arm-purview': file:./projects/arm-purview.tgz
|
||||
|
@ -199,6 +200,7 @@ dependencies:
|
|||
'@rush-temp/arm-notificationhubs': file:projects/arm-notificationhubs.tgz
|
||||
'@rush-temp/arm-operationalinsights': file:projects/arm-operationalinsights.tgz
|
||||
'@rush-temp/arm-operations': file:projects/arm-operations.tgz
|
||||
'@rush-temp/arm-orbital': file:projects/arm-orbital.tgz
|
||||
'@rush-temp/arm-policy': file:projects/arm-policy.tgz
|
||||
'@rush-temp/arm-postgresql': file:projects/arm-postgresql.tgz
|
||||
'@rush-temp/arm-purview': file:projects/arm-purview.tgz
|
||||
|
@ -9252,6 +9254,27 @@ packages:
|
|||
uglify-js: 3.14.3
|
||||
dev: false
|
||||
|
||||
file:projects/arm-orbital.tgz:
|
||||
resolution: {integrity: sha512-a+8J0Bt6Uy4UhaHEMMyEhsUKR1JMRiNUDlNfMZtm8J3s8PMYtV/V0ELVmN/CnX1nuQ4/CrsKYiYyTvaUeZamuQ==, tarball: file:projects/arm-orbital.tgz}
|
||||
name: '@rush-temp/arm-orbital'
|
||||
version: 0.0.0
|
||||
dependencies:
|
||||
'@microsoft/api-extractor': 7.18.19
|
||||
'@rollup/plugin-commonjs': 11.0.2_rollup@1.32.1
|
||||
'@rollup/plugin-json': 4.1.0_rollup@1.32.1
|
||||
'@rollup/plugin-multi-entry': 3.0.1_rollup@1.32.1
|
||||
'@rollup/plugin-node-resolve': 8.4.0_rollup@1.32.1
|
||||
cross-env: 7.0.3
|
||||
mkdirp: 1.0.4
|
||||
mocha: 7.2.0
|
||||
rimraf: 3.0.2
|
||||
rollup: 1.32.1
|
||||
rollup-plugin-sourcemaps: 0.4.2_rollup@1.32.1
|
||||
tslib: 2.3.1
|
||||
typescript: 4.2.4
|
||||
uglify-js: 3.14.3
|
||||
dev: false
|
||||
|
||||
file:projects/arm-policy.tgz:
|
||||
resolution: {integrity: sha512-qV+rEimyGpmAxdLaIKUU1NI1clVddBq6NaE6GbUfg+iXADJpRxGebkSzP6pcH2mWdNZrCBId462AxKzSQvXLEg==, tarball: file:projects/arm-policy.tgz}
|
||||
name: '@rush-temp/arm-policy'
|
||||
|
|
|
@ -11,3 +11,6 @@ https://github.com/Azure/azure-digital-twins/blob/private-preview/Documentation/
|
|||
https://docs.microsoft.com/javascript/api/@azure/arm-desktopvirtualization
|
||||
https://github.com/Azure/azure-sdk-for-js/tree/main/sdk/desktopvirtualization/arm-desktopvirtualization
|
||||
https://docs.microsoft.com/javascript/api/@azure/arm-datalake-analytics?view=azure-node-preview
|
||||
https://docs.microsoft.com/javascript/api/@azure/arm-orbital
|
||||
https://github.com/Azure/azure-sdk-for-js/tree/main/sdk/orbital/arm-orbital
|
||||
https://docs.microsoft.com/javascript/api/@azure/arm-orbital?view=azure-node-preview
|
||||
|
|
|
@ -1105,6 +1105,11 @@
|
|||
"packageName": "@azure/arm-managementgroups",
|
||||
"projectFolder": "sdk/managementgroups/arm-managementgroups",
|
||||
"versionPolicyName": "management"
|
||||
},
|
||||
{
|
||||
"packageName": "@azure/arm-orbital",
|
||||
"projectFolder": "sdk/orbital/arm-orbital",
|
||||
"versionPolicyName": "management"
|
||||
}
|
||||
]
|
||||
}
|
||||
}
|
||||
|
|
|
@ -0,0 +1,3 @@
|
|||
## 1.0.0-beta.1 (2021-11-22)
|
||||
|
||||
- Initial Release
|
|
@ -0,0 +1,21 @@
|
|||
The MIT License (MIT)
|
||||
|
||||
Copyright (c) 2021 Microsoft
|
||||
|
||||
Permission is hereby granted, free of charge, to any person obtaining a copy
|
||||
of this software and associated documentation files (the "Software"), to deal
|
||||
in the Software without restriction, including without limitation the rights
|
||||
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
||||
copies of the Software, and to permit persons to whom the Software is
|
||||
furnished to do so, subject to the following conditions:
|
||||
|
||||
The above copyright notice and this permission notice shall be included in all
|
||||
copies or substantial portions of the Software.
|
||||
|
||||
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
||||
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
||||
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
||||
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
||||
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
||||
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
||||
SOFTWARE.
|
|
@ -0,0 +1,98 @@
|
|||
# Azure Service client library for JavaScript
|
||||
|
||||
This package contains an isomorphic SDK (runs both in Node.js and in browsers) for Azure Service client.
|
||||
|
||||
Azure Orbital service
|
||||
|
||||
[Source code](https://github.com/Azure/azure-sdk-for-js/tree/main/sdk/orbital/arm-orbital) |
|
||||
[Package (NPM)](https://www.npmjs.com/package/@azure/arm-orbital) |
|
||||
[API reference documentation](https://docs.microsoft.com/javascript/api/@azure/arm-orbital?view=azure-node-preview) |
|
||||
[Samples](https://github.com/Azure-Samples/azure-samples-js-management)
|
||||
|
||||
## Getting started
|
||||
|
||||
### Currently supported environments
|
||||
|
||||
- [LTS versions of Node.js](https://nodejs.org/about/releases/)
|
||||
- Latest versions of Safari, Chrome, Edge and Firefox.
|
||||
|
||||
### Prerequisites
|
||||
|
||||
- An [Azure subscription][azure_sub].
|
||||
|
||||
### Install the `@azure/arm-orbital` package
|
||||
|
||||
Install the Azure Service client library for JavaScript with `npm`:
|
||||
|
||||
```bash
|
||||
npm install @azure/arm-orbital
|
||||
```
|
||||
|
||||
### Create and authenticate a `AzureOrbital`
|
||||
|
||||
To create a client object to access the Azure Service API, you will need the `endpoint` of your Azure Service resource and a `credential`. The Azure Service client can use Azure Active Directory credentials to authenticate.
|
||||
You can find the endpoint for your Azure Service resource in the [Azure Portal][azure_portal].
|
||||
|
||||
You can authenticate with Azure Active Directory using a credential from the [@azure/identity][azure_identity] library or [an existing AAD Token](https://github.com/Azure/azure-sdk-for-js/blob/master/sdk/identity/identity/samples/AzureIdentityExamples.md#authenticating-with-a-pre-fetched-access-token).
|
||||
|
||||
To use the [DefaultAzureCredential][defaultazurecredential] provider shown below, or other credential providers provided with the Azure SDK, please install the `@azure/identity` package:
|
||||
|
||||
```bash
|
||||
npm install @azure/identity
|
||||
```
|
||||
|
||||
You will also need to **register a new AAD application and grant access to Azure Service** by assigning the suitable role to your service principal (note: roles such as `"Owner"` will not grant the necessary permissions).
|
||||
Set the values of the client ID, tenant ID, and client secret of the AAD application as environment variables: `AZURE_CLIENT_ID`, `AZURE_TENANT_ID`, `AZURE_CLIENT_SECRET`.
|
||||
|
||||
For more information about how to create an Azure AD Application check out [this guide](https://docs.microsoft.com/azure/active-directory/develop/howto-create-service-principal-portal).
|
||||
|
||||
```javascript
|
||||
const { AzureOrbital } = require("@azure/arm-orbital");
|
||||
const { DefaultAzureCredential } = require("@azure/identity");
|
||||
const subscriptionId = "00000000-0000-0000-0000-000000000000";
|
||||
const client = new AzureOrbital(new DefaultAzureCredential(), subscriptionId);
|
||||
```
|
||||
|
||||
|
||||
### JavaScript Bundle
|
||||
To use this client library in the browser, first you need to use a bundler. For details on how to do this, please refer to our [bundling documentation](https://aka.ms/AzureSDKBundling).
|
||||
|
||||
## Key concepts
|
||||
|
||||
### AzureOrbital
|
||||
|
||||
`AzureOrbital` is the primary interface for developers using the Azure Service client library. Explore the methods on this client object to understand the different features of the Azure Service service that you can access.
|
||||
|
||||
## Troubleshooting
|
||||
|
||||
### Logging
|
||||
|
||||
Enabling logging may help uncover useful information about failures. In order to see a log of HTTP requests and responses, set the `AZURE_LOG_LEVEL` environment variable to `info`. Alternatively, logging can be enabled at runtime by calling `setLogLevel` in the `@azure/logger`:
|
||||
|
||||
```javascript
|
||||
const { setLogLevel } = require("@azure/logger");
|
||||
setLogLevel("info");
|
||||
```
|
||||
|
||||
For more detailed instructions on how to enable logs, you can look at the [@azure/logger package docs](https://github.com/Azure/azure-sdk-for-js/tree/main/sdk/core/logger).
|
||||
|
||||
## Next steps
|
||||
|
||||
Please take a look at the [samples](https://github.com/Azure-Samples/azure-samples-js-management) directory for detailed examples on how to use this library.
|
||||
|
||||
## Contributing
|
||||
|
||||
If you'd like to contribute to this library, please read the [contributing guide](https://github.com/Azure/azure-sdk-for-js/blob/main/CONTRIBUTING.md) to learn more about how to build and test the code.
|
||||
|
||||
## Related projects
|
||||
|
||||
- [Microsoft Azure SDK for JavaScript](https://github.com/Azure/azure-sdk-for-js)
|
||||
|
||||
![Impressions](https://azure-sdk-impressions.azurewebsites.net/api/impressions/azure-sdk-for-js%2Fsdk%2Forbital%2Farm-orbital%2FREADME.png)
|
||||
|
||||
[azure_cli]: https://docs.microsoft.com/cli/azure
|
||||
[azure_sub]: https://azure.microsoft.com/free/
|
||||
[azure_sub]: https://azure.microsoft.com/free/
|
||||
[azure_portal]: https://portal.azure.com
|
||||
[azure_identity]: https://github.com/Azure/azure-sdk-for-js/tree/main/sdk/identity/identity
|
||||
[defaultazurecredential]: https://github.com/Azure/azure-sdk-for-js/tree/main/sdk/identity/identity#defaultazurecredential
|
|
@ -0,0 +1,7 @@
|
|||
{
|
||||
"commit": "e827b527ff33475b4b561d445f06bf4b184e3efe",
|
||||
"readme": "specification/orbital/resource-manager/readme.md",
|
||||
"autorest_command": "autorest --version=3.1.3 --typescript --modelerfour.lenient-model-deduplication --head-as-boolean=true --license-header=MICROSOFT_MIT_NO_VERSION --generate-test --typescript-sdks-folder=D:\\mydev\\azure-sdk-for-js ../azure-rest-api-specs/specification/orbital/resource-manager/readme.md --use=@autorest/typescript@6.0.0-alpha.15.20211116.1",
|
||||
"repository_url": "https://github.com/Azure/azure-rest-api-specs.git",
|
||||
"use": "@autorest/typescript@6.0.0-alpha.15.20211116.1"
|
||||
}
|
|
@ -0,0 +1,18 @@
|
|||
{
|
||||
"$schema": "https://developer.microsoft.com/json-schemas/api-extractor/v7/api-extractor.schema.json",
|
||||
"mainEntryPointFilePath": "./dist-esm/src/index.d.ts",
|
||||
"docModel": { "enabled": true },
|
||||
"apiReport": { "enabled": true, "reportFolder": "./review" },
|
||||
"dtsRollup": {
|
||||
"enabled": true,
|
||||
"untrimmedFilePath": "",
|
||||
"publicTrimmedFilePath": "./types/arm-orbital.d.ts"
|
||||
},
|
||||
"messages": {
|
||||
"tsdocMessageReporting": { "default": { "logLevel": "none" } },
|
||||
"extractorMessageReporting": {
|
||||
"ae-missing-release-tag": { "logLevel": "none" },
|
||||
"ae-unresolved-link": { "logLevel": "none" }
|
||||
}
|
||||
}
|
||||
}
|
|
@ -0,0 +1,92 @@
|
|||
{
|
||||
"name": "@azure/arm-orbital",
|
||||
"sdk-type": "mgmt",
|
||||
"author": "Microsoft Corporation",
|
||||
"description": "A generated SDK for AzureOrbital.",
|
||||
"version": "1.0.0-beta.1",
|
||||
"engines": { "node": ">=12.0.0" },
|
||||
"dependencies": {
|
||||
"@azure/core-lro": "^2.2.0",
|
||||
"@azure/abort-controller": "^1.0.0",
|
||||
"@azure/core-paging": "^1.2.0",
|
||||
"@azure/core-client": "^1.0.0",
|
||||
"@azure/core-auth": "^1.3.0",
|
||||
"@azure/core-rest-pipeline": "^1.1.0",
|
||||
"tslib": "^2.2.0"
|
||||
},
|
||||
"keywords": ["node", "azure", "typescript", "browser", "isomorphic"],
|
||||
"license": "MIT",
|
||||
"main": "./dist/index.js",
|
||||
"module": "./dist-esm/src/index.js",
|
||||
"types": "./types/arm-orbital.d.ts",
|
||||
"devDependencies": {
|
||||
"@microsoft/api-extractor": "^7.18.11",
|
||||
"@rollup/plugin-commonjs": "11.0.2",
|
||||
"@rollup/plugin-json": "^4.0.0",
|
||||
"@rollup/plugin-multi-entry": "^3.0.0",
|
||||
"@rollup/plugin-node-resolve": "^8.0.0",
|
||||
"mkdirp": "^1.0.4",
|
||||
"rollup": "^1.16.3",
|
||||
"rollup-plugin-sourcemaps": "^0.4.2",
|
||||
"typescript": "~4.2.0",
|
||||
"uglify-js": "^3.4.9",
|
||||
"rimraf": "^3.0.0",
|
||||
"@azure/identity": "^2.0.1",
|
||||
"@azure-tools/test-recorder": "^1.0.0",
|
||||
"mocha": "^7.1.1",
|
||||
"cross-env": "^7.0.2"
|
||||
},
|
||||
"homepage": "https://github.com/Azure/azure-sdk-for-js/tree/main/sdk/orbital/arm-orbital",
|
||||
"repository": {
|
||||
"type": "git",
|
||||
"url": "https://github.com/Azure/azure-sdk-for-js.git"
|
||||
},
|
||||
"bugs": { "url": "https://github.com/Azure/azure-sdk-for-js/issues" },
|
||||
"files": [
|
||||
"dist/**/*.js",
|
||||
"dist/**/*.js.map",
|
||||
"dist/**/*.d.ts",
|
||||
"dist/**/*.d.ts.map",
|
||||
"dist-esm/**/*.js",
|
||||
"dist-esm/**/*.js.map",
|
||||
"dist-esm/**/*.d.ts",
|
||||
"dist-esm/**/*.d.ts.map",
|
||||
"src/**/*.ts",
|
||||
"README.md",
|
||||
"LICENSE",
|
||||
"rollup.config.js",
|
||||
"tsconfig.json",
|
||||
"review/*",
|
||||
"CHANGELOG.md",
|
||||
"types/*"
|
||||
],
|
||||
"scripts": {
|
||||
"build": "npm run clean && tsc && rollup -c 2>&1 && npm run minify && mkdirp ./review && npm run extract-api",
|
||||
"minify": "uglifyjs -c -m --comments --source-map \"content='./dist/index.js.map'\" -o ./dist/index.min.js ./dist/index.js",
|
||||
"prepack": "npm run build",
|
||||
"pack": "npm pack 2>&1",
|
||||
"extract-api": "api-extractor run --local",
|
||||
"lint": "echo skipped",
|
||||
"audit": "echo skipped",
|
||||
"clean": "rimraf dist dist-browser dist-esm test-dist temp types *.tgz *.log",
|
||||
"build:node": "echo skipped",
|
||||
"build:browser": "echo skipped",
|
||||
"build:test": "echo skipped",
|
||||
"build:samples": "echo skipped.",
|
||||
"check-format": "echo skipped",
|
||||
"execute:samples": "echo skipped",
|
||||
"format": "echo skipped",
|
||||
"test": "npm run integration-test",
|
||||
"test:node": "echo skipped",
|
||||
"test:browser": "echo skipped",
|
||||
"unit-test": "npm run unit-test:node && npm run unit-test:browser",
|
||||
"unit-test:node": "cross-env TEST_MODE=playback npm run integration-test:node",
|
||||
"unit-test:browser": "echo skipped",
|
||||
"integration-test": "npm run integration-test:node && npm run integration-test:browser",
|
||||
"integration-test:node": "mocha -r esm --require ts-node/register --timeout 1200000 --full-trace test/*.ts --reporter ../../../common/tools/mocha-multi-reporter.js",
|
||||
"integration-test:browser": "echo skipped",
|
||||
"docs": "echo skipped"
|
||||
},
|
||||
"sideEffects": false,
|
||||
"autoPublish": true
|
||||
}
|
5
sdk/orbital/arm-orbital/recordings/node/my_test/recording_sample_test.js
сгенерированный
Normal file
5
sdk/orbital/arm-orbital/recordings/node/my_test/recording_sample_test.js
сгенерированный
Normal file
|
@ -0,0 +1,5 @@
|
|||
let nock = require('nock');
|
||||
|
||||
module.exports.hash = "7a6be38bb8cb644d64b4094802301751";
|
||||
|
||||
module.exports.testInfo = {"uniqueName":{},"newDate":{}}
|
|
@ -0,0 +1,600 @@
|
|||
## API Report File for "@azure/arm-orbital"
|
||||
|
||||
> Do not edit this file. It is a report generated by [API Extractor](https://api-extractor.com/).
|
||||
|
||||
```ts
|
||||
|
||||
import * as coreAuth from '@azure/core-auth';
|
||||
import * as coreClient from '@azure/core-client';
|
||||
import { PagedAsyncIterableIterator } from '@azure/core-paging';
|
||||
import { PollerLike } from '@azure/core-lro';
|
||||
import { PollOperationState } from '@azure/core-lro';
|
||||
|
||||
// @public
|
||||
export type ActionType = string;
|
||||
|
||||
// @public
|
||||
export type AuthorizationStatus = "Allowed" | "Pending" | "Denied";
|
||||
|
||||
// @public
|
||||
export type AutoTrackingConfiguration = "disabled" | "xBand" | "sBand";
|
||||
|
||||
// @public
|
||||
export interface AvailableContacts {
|
||||
readonly endAzimuthDegrees?: number;
|
||||
readonly endElevationDegrees?: number;
|
||||
readonly groundStationName?: string;
|
||||
readonly maximumElevationDegrees?: number;
|
||||
readonly rxEndTime?: Date;
|
||||
readonly rxStartTime?: Date;
|
||||
spacecraft?: ResourceReference;
|
||||
readonly startAzimuthDegrees?: number;
|
||||
readonly startElevationDegrees?: number;
|
||||
readonly txEndTime?: Date;
|
||||
readonly txStartTime?: Date;
|
||||
}
|
||||
|
||||
// @public
|
||||
export interface AvailableContactsListResult {
|
||||
readonly nextLink?: string;
|
||||
value?: AvailableContacts[];
|
||||
}
|
||||
|
||||
// @public
|
||||
export interface AvailableGroundStation {
|
||||
altitudeMeters?: number;
|
||||
city?: string;
|
||||
readonly id?: string;
|
||||
latitudeDegrees?: number;
|
||||
location?: string;
|
||||
longitudeDegrees?: number;
|
||||
readonly name?: string;
|
||||
providerName?: string;
|
||||
readonly type?: string;
|
||||
}
|
||||
|
||||
// @public
|
||||
export interface AvailableGroundStationListResult {
|
||||
readonly nextLink?: string;
|
||||
value?: AvailableGroundStation[];
|
||||
}
|
||||
|
||||
// @public
|
||||
export interface AvailableGroundStations {
|
||||
get(groundStationName: string, options?: AvailableGroundStationsGetOptionalParams): Promise<AvailableGroundStationsGetResponse>;
|
||||
listByCapability(capability: Enum6, options?: AvailableGroundStationsListByCapabilityOptionalParams): PagedAsyncIterableIterator<AvailableGroundStation>;
|
||||
}
|
||||
|
||||
// @public
|
||||
export interface AvailableGroundStationsGetOptionalParams extends coreClient.OperationOptions {
|
||||
}
|
||||
|
||||
// @public
|
||||
export type AvailableGroundStationsGetResponse = AvailableGroundStation;
|
||||
|
||||
// @public
|
||||
export interface AvailableGroundStationsListByCapabilityNextOptionalParams extends coreClient.OperationOptions {
|
||||
}
|
||||
|
||||
// @public
|
||||
export type AvailableGroundStationsListByCapabilityNextResponse = AvailableGroundStationListResult;
|
||||
|
||||
// @public
|
||||
export interface AvailableGroundStationsListByCapabilityOptionalParams extends coreClient.OperationOptions {
|
||||
}
|
||||
|
||||
// @public
|
||||
export type AvailableGroundStationsListByCapabilityResponse = AvailableGroundStationListResult;
|
||||
|
||||
// @public (undocumented)
|
||||
export class AzureOrbital extends AzureOrbitalContext {
|
||||
constructor(credentials: coreAuth.TokenCredential, subscriptionId: string, options?: AzureOrbitalOptionalParams);
|
||||
// (undocumented)
|
||||
availableGroundStations: AvailableGroundStations;
|
||||
// (undocumented)
|
||||
contactProfiles: ContactProfiles;
|
||||
// (undocumented)
|
||||
contacts: Contacts;
|
||||
// (undocumented)
|
||||
operations: Operations;
|
||||
// (undocumented)
|
||||
spacecrafts: Spacecrafts;
|
||||
}
|
||||
|
||||
// @public (undocumented)
|
||||
export class AzureOrbitalContext extends coreClient.ServiceClient {
|
||||
// (undocumented)
|
||||
$host: string;
|
||||
constructor(credentials: coreAuth.TokenCredential, subscriptionId: string, options?: AzureOrbitalOptionalParams);
|
||||
// (undocumented)
|
||||
apiVersion: string;
|
||||
// (undocumented)
|
||||
subscriptionId: string;
|
||||
}
|
||||
|
||||
// @public
|
||||
export interface AzureOrbitalOptionalParams extends coreClient.ServiceClientOptions {
|
||||
$host?: string;
|
||||
apiVersion?: string;
|
||||
endpoint?: string;
|
||||
}
|
||||
|
||||
// @public
|
||||
export type Capability = string;
|
||||
|
||||
// @public
|
||||
export interface CloudError {
|
||||
error?: CloudErrorBody;
|
||||
}
|
||||
|
||||
// @public
|
||||
export interface CloudErrorBody {
|
||||
code?: string;
|
||||
details?: CloudErrorBody[];
|
||||
message?: string;
|
||||
target?: string;
|
||||
}
|
||||
|
||||
// @public
|
||||
export type Contact = ProxyResource & {
|
||||
readonly etag?: string;
|
||||
readonly status?: Status;
|
||||
reservationStartTime?: Date;
|
||||
reservationEndTime?: Date;
|
||||
readonly rxStartTime?: Date;
|
||||
readonly rxEndTime?: Date;
|
||||
readonly txStartTime?: Date;
|
||||
readonly txEndTime?: Date;
|
||||
readonly errorMessage?: string;
|
||||
readonly maximumElevationDegrees?: number;
|
||||
readonly startAzimuthDegrees?: number;
|
||||
readonly endAzimuthDegrees?: number;
|
||||
groundStationName?: string;
|
||||
readonly startElevationDegrees?: number;
|
||||
readonly endElevationDegrees?: number;
|
||||
contactProfile?: ResourceReference;
|
||||
};
|
||||
|
||||
// @public
|
||||
export interface ContactListResult {
|
||||
readonly nextLink?: string;
|
||||
value?: Contact[];
|
||||
}
|
||||
|
||||
// @public
|
||||
export interface ContactParameters {
|
||||
contactProfile: ResourceReference;
|
||||
endTime: Date;
|
||||
groundStationName: string;
|
||||
startTime: Date;
|
||||
}
|
||||
|
||||
// @public
|
||||
export type ContactProfile = TrackedResource & {
|
||||
readonly etag?: string;
|
||||
minimumViableContactDuration?: string;
|
||||
minimumElevationDegrees?: number;
|
||||
autoTrackingConfiguration?: AutoTrackingConfiguration;
|
||||
links?: ContactProfileLink[];
|
||||
};
|
||||
|
||||
// @public
|
||||
export interface ContactProfileLink {
|
||||
channels: ContactProfileLinkChannel[];
|
||||
direction: Direction;
|
||||
eirpdBW?: number;
|
||||
gainOverTemperature?: number;
|
||||
polarization: Polarization;
|
||||
}
|
||||
|
||||
// @public
|
||||
export interface ContactProfileLinkChannel {
|
||||
bandwidthMHz: number;
|
||||
centerFrequencyMHz: number;
|
||||
decodingConfiguration?: string;
|
||||
demodulationConfiguration?: string;
|
||||
encodingConfiguration?: string;
|
||||
endPoint: EndPoint;
|
||||
modulationConfiguration?: string;
|
||||
}
|
||||
|
||||
// @public
|
||||
export interface ContactProfileListResult {
|
||||
readonly nextLink?: string;
|
||||
value?: ContactProfile[];
|
||||
}
|
||||
|
||||
// @public
|
||||
export interface ContactProfiles {
|
||||
beginCreateOrUpdate(resourceGroupName: string, contactProfileName: string, location: string, options?: ContactProfilesCreateOrUpdateOptionalParams): Promise<PollerLike<PollOperationState<ContactProfilesCreateOrUpdateResponse>, ContactProfilesCreateOrUpdateResponse>>;
|
||||
beginCreateOrUpdateAndWait(resourceGroupName: string, contactProfileName: string, location: string, options?: ContactProfilesCreateOrUpdateOptionalParams): Promise<ContactProfilesCreateOrUpdateResponse>;
|
||||
beginDelete(resourceGroupName: string, contactProfileName: string, options?: ContactProfilesDeleteOptionalParams): Promise<PollerLike<PollOperationState<void>, void>>;
|
||||
beginDeleteAndWait(resourceGroupName: string, contactProfileName: string, options?: ContactProfilesDeleteOptionalParams): Promise<void>;
|
||||
get(resourceGroupName: string, contactProfileName: string, options?: ContactProfilesGetOptionalParams): Promise<ContactProfilesGetResponse>;
|
||||
list(resourceGroupName: string, options?: ContactProfilesListOptionalParams): PagedAsyncIterableIterator<ContactProfile>;
|
||||
listBySubscription(options?: ContactProfilesListBySubscriptionOptionalParams): PagedAsyncIterableIterator<ContactProfile>;
|
||||
updateTags(resourceGroupName: string, contactProfileName: string, parameters: TagsObject, options?: ContactProfilesUpdateTagsOptionalParams): Promise<ContactProfilesUpdateTagsResponse>;
|
||||
}
|
||||
|
||||
// @public
|
||||
export interface ContactProfilesCreateOrUpdateOptionalParams extends coreClient.OperationOptions {
|
||||
autoTrackingConfiguration?: AutoTrackingConfiguration;
|
||||
links?: ContactProfileLink[];
|
||||
minimumElevationDegrees?: number;
|
||||
minimumViableContactDuration?: string;
|
||||
resumeFrom?: string;
|
||||
tags?: {
|
||||
[propertyName: string]: string;
|
||||
};
|
||||
updateIntervalInMs?: number;
|
||||
}
|
||||
|
||||
// @public
|
||||
export type ContactProfilesCreateOrUpdateResponse = ContactProfile;
|
||||
|
||||
// @public
|
||||
export interface ContactProfilesDeleteOptionalParams extends coreClient.OperationOptions {
|
||||
resumeFrom?: string;
|
||||
updateIntervalInMs?: number;
|
||||
}
|
||||
|
||||
// @public
|
||||
export interface ContactProfilesGetOptionalParams extends coreClient.OperationOptions {
|
||||
}
|
||||
|
||||
// @public
|
||||
export type ContactProfilesGetResponse = ContactProfile;
|
||||
|
||||
// @public
|
||||
export interface ContactProfilesListBySubscriptionOptionalParams extends coreClient.OperationOptions {
|
||||
}
|
||||
|
||||
// @public
|
||||
export type ContactProfilesListBySubscriptionResponse = ContactProfileListResult;
|
||||
|
||||
// @public
|
||||
export interface ContactProfilesListOptionalParams extends coreClient.OperationOptions {
|
||||
}
|
||||
|
||||
// @public
|
||||
export type ContactProfilesListResponse = ContactProfileListResult;
|
||||
|
||||
// @public
|
||||
export interface ContactProfilesUpdateTagsOptionalParams extends coreClient.OperationOptions {
|
||||
}
|
||||
|
||||
// @public
|
||||
export type ContactProfilesUpdateTagsResponse = ContactProfile;
|
||||
|
||||
// @public
|
||||
export interface Contacts {
|
||||
beginCreate(resourceGroupName: string, spacecraftName: string, contactName: string, parameters: Contact, options?: ContactsCreateOptionalParams): Promise<PollerLike<PollOperationState<ContactsCreateResponse>, ContactsCreateResponse>>;
|
||||
beginCreateAndWait(resourceGroupName: string, spacecraftName: string, contactName: string, parameters: Contact, options?: ContactsCreateOptionalParams): Promise<ContactsCreateResponse>;
|
||||
beginDelete(resourceGroupName: string, spacecraftName: string, contactName: string, options?: ContactsDeleteOptionalParams): Promise<PollerLike<PollOperationState<void>, void>>;
|
||||
beginDeleteAndWait(resourceGroupName: string, spacecraftName: string, contactName: string, options?: ContactsDeleteOptionalParams): Promise<void>;
|
||||
get(resourceGroupName: string, spacecraftName: string, contactName: string, options?: ContactsGetOptionalParams): Promise<ContactsGetResponse>;
|
||||
list(resourceGroupName: string, spacecraftName: string, options?: ContactsListOptionalParams): PagedAsyncIterableIterator<Contact>;
|
||||
}
|
||||
|
||||
// @public
|
||||
export interface ContactsCreateOptionalParams extends coreClient.OperationOptions {
|
||||
resumeFrom?: string;
|
||||
updateIntervalInMs?: number;
|
||||
}
|
||||
|
||||
// @public
|
||||
export type ContactsCreateResponse = Contact;
|
||||
|
||||
// @public
|
||||
export interface ContactsDeleteOptionalParams extends coreClient.OperationOptions {
|
||||
resumeFrom?: string;
|
||||
updateIntervalInMs?: number;
|
||||
}
|
||||
|
||||
// @public
|
||||
export interface ContactsGetOptionalParams extends coreClient.OperationOptions {
|
||||
}
|
||||
|
||||
// @public
|
||||
export type ContactsGetResponse = Contact;
|
||||
|
||||
// @public
|
||||
export interface ContactsListOptionalParams extends coreClient.OperationOptions {
|
||||
}
|
||||
|
||||
// @public
|
||||
export type ContactsListResponse = ContactListResult;
|
||||
|
||||
// @public
|
||||
export type CreatedByType = string;
|
||||
|
||||
// @public
|
||||
export type Direction = string;
|
||||
|
||||
// @public
|
||||
export interface EndPoint {
|
||||
endPointName: string;
|
||||
ipAddress: string;
|
||||
port: string;
|
||||
protocol: Protocol;
|
||||
}
|
||||
|
||||
// @public
|
||||
export type Enum6 = string;
|
||||
|
||||
// @public
|
||||
export enum KnownActionType {
|
||||
// (undocumented)
|
||||
Internal = "Internal"
|
||||
}
|
||||
|
||||
// @public
|
||||
export enum KnownCapability {
|
||||
// (undocumented)
|
||||
Communication = "Communication",
|
||||
// (undocumented)
|
||||
EarthObservation = "EarthObservation"
|
||||
}
|
||||
|
||||
// @public
|
||||
export enum KnownCreatedByType {
|
||||
// (undocumented)
|
||||
Application = "Application",
|
||||
// (undocumented)
|
||||
Key = "Key",
|
||||
// (undocumented)
|
||||
ManagedIdentity = "ManagedIdentity",
|
||||
// (undocumented)
|
||||
User = "User"
|
||||
}
|
||||
|
||||
// @public
|
||||
export enum KnownDirection {
|
||||
// (undocumented)
|
||||
Downlink = "downlink",
|
||||
// (undocumented)
|
||||
Uplink = "uplink"
|
||||
}
|
||||
|
||||
// @public
|
||||
export enum KnownEnum6 {
|
||||
// (undocumented)
|
||||
Communication = "Communication",
|
||||
// (undocumented)
|
||||
EarthObservation = "EarthObservation"
|
||||
}
|
||||
|
||||
// @public
|
||||
export enum KnownOrigin {
|
||||
// (undocumented)
|
||||
System = "system",
|
||||
// (undocumented)
|
||||
User = "user",
|
||||
// (undocumented)
|
||||
UserSystem = "user,system"
|
||||
}
|
||||
|
||||
// @public
|
||||
export enum KnownPolarization {
|
||||
// (undocumented)
|
||||
DualRhcpLhcp = "dualRhcpLhcp",
|
||||
// (undocumented)
|
||||
Lhcp = "LHCP",
|
||||
// (undocumented)
|
||||
LinearHorizontal = "linearHorizontal",
|
||||
// (undocumented)
|
||||
LinearVertical = "linearVertical",
|
||||
// (undocumented)
|
||||
Rhcp = "RHCP"
|
||||
}
|
||||
|
||||
// @public
|
||||
export enum KnownProtocol {
|
||||
// (undocumented)
|
||||
TCP = "TCP",
|
||||
// (undocumented)
|
||||
UDP = "UDP"
|
||||
}
|
||||
|
||||
// @public
|
||||
export interface Operation {
|
||||
readonly actionType?: ActionType;
|
||||
display?: OperationDisplay;
|
||||
readonly isDataAction?: boolean;
|
||||
readonly name?: string;
|
||||
readonly origin?: Origin;
|
||||
}
|
||||
|
||||
// @public
|
||||
export interface OperationDisplay {
|
||||
readonly description?: string;
|
||||
readonly operation?: string;
|
||||
readonly provider?: string;
|
||||
readonly resource?: string;
|
||||
}
|
||||
|
||||
// @public
|
||||
export interface OperationListResult {
|
||||
readonly nextLink?: string;
|
||||
readonly value?: Operation[];
|
||||
}
|
||||
|
||||
// @public
|
||||
export interface Operations {
|
||||
list(options?: OperationsListOptionalParams): PagedAsyncIterableIterator<Operation>;
|
||||
}
|
||||
|
||||
// @public
|
||||
export interface OperationsListOptionalParams extends coreClient.OperationOptions {
|
||||
}
|
||||
|
||||
// @public
|
||||
export type OperationsListResponse = OperationListResult;
|
||||
|
||||
// @public
|
||||
export type Origin = string;
|
||||
|
||||
// @public
|
||||
export type Polarization = string;
|
||||
|
||||
// @public
|
||||
export type Protocol = string;
|
||||
|
||||
// @public
|
||||
export type ProxyResource = Resource & {};
|
||||
|
||||
// @public
|
||||
export interface Resource {
|
||||
readonly id?: string;
|
||||
readonly name?: string;
|
||||
readonly systemData?: SystemData;
|
||||
readonly type?: string;
|
||||
}
|
||||
|
||||
// @public
|
||||
export interface ResourceIdListResult {
|
||||
readonly nextLink?: string;
|
||||
value?: ResourceIdListResultValueItem[];
|
||||
}
|
||||
|
||||
// @public (undocumented)
|
||||
export interface ResourceIdListResultValueItem {
|
||||
id?: string;
|
||||
}
|
||||
|
||||
// @public
|
||||
export interface ResourceReference {
|
||||
id?: string;
|
||||
}
|
||||
|
||||
// @public
|
||||
export type Spacecraft = TrackedResource & {
|
||||
readonly etag?: string;
|
||||
noradId?: string;
|
||||
readonly authorizationStatus?: AuthorizationStatus;
|
||||
readonly authorizationStatusExtended?: string;
|
||||
titleLine?: string;
|
||||
tleLine1?: string;
|
||||
tleLine2?: string;
|
||||
links?: SpacecraftLink[];
|
||||
};
|
||||
|
||||
// @public
|
||||
export interface SpacecraftLink {
|
||||
bandwidthMHz: number;
|
||||
centerFrequencyMHz: number;
|
||||
direction: Direction;
|
||||
polarization: Polarization;
|
||||
}
|
||||
|
||||
// @public
|
||||
export interface SpacecraftListResult {
|
||||
readonly nextLink?: string;
|
||||
value?: Spacecraft[];
|
||||
}
|
||||
|
||||
// @public
|
||||
export interface Spacecrafts {
|
||||
beginCreateOrUpdate(resourceGroupName: string, spacecraftName: string, location: string, options?: SpacecraftsCreateOrUpdateOptionalParams): Promise<PollerLike<PollOperationState<SpacecraftsCreateOrUpdateResponse>, SpacecraftsCreateOrUpdateResponse>>;
|
||||
beginCreateOrUpdateAndWait(resourceGroupName: string, spacecraftName: string, location: string, options?: SpacecraftsCreateOrUpdateOptionalParams): Promise<SpacecraftsCreateOrUpdateResponse>;
|
||||
beginDelete(resourceGroupName: string, spacecraftName: string, options?: SpacecraftsDeleteOptionalParams): Promise<PollerLike<PollOperationState<void>, void>>;
|
||||
beginDeleteAndWait(resourceGroupName: string, spacecraftName: string, options?: SpacecraftsDeleteOptionalParams): Promise<void>;
|
||||
beginListAvailableContacts(resourceGroupName: string, spacecraftName: string, contactProfile: ResourceReference, groundStationName: string, startTime: Date, endTime: Date, options?: SpacecraftsListAvailableContactsOptionalParams): Promise<PollerLike<PollOperationState<SpacecraftsListAvailableContactsResponse>, SpacecraftsListAvailableContactsResponse>>;
|
||||
beginListAvailableContactsAndWait(resourceGroupName: string, spacecraftName: string, contactProfile: ResourceReference, groundStationName: string, startTime: Date, endTime: Date, options?: SpacecraftsListAvailableContactsOptionalParams): Promise<SpacecraftsListAvailableContactsResponse>;
|
||||
get(resourceGroupName: string, spacecraftName: string, options?: SpacecraftsGetOptionalParams): Promise<SpacecraftsGetResponse>;
|
||||
list(resourceGroupName: string, options?: SpacecraftsListOptionalParams): PagedAsyncIterableIterator<Spacecraft>;
|
||||
listBySubscription(options?: SpacecraftsListBySubscriptionOptionalParams): PagedAsyncIterableIterator<Spacecraft>;
|
||||
updateTags(resourceGroupName: string, spacecraftName: string, parameters: TagsObject, options?: SpacecraftsUpdateTagsOptionalParams): Promise<SpacecraftsUpdateTagsResponse>;
|
||||
}
|
||||
|
||||
// @public
|
||||
export interface SpacecraftsCreateOrUpdateOptionalParams extends coreClient.OperationOptions {
|
||||
links?: SpacecraftLink[];
|
||||
noradId?: string;
|
||||
resumeFrom?: string;
|
||||
tags?: {
|
||||
[propertyName: string]: string;
|
||||
};
|
||||
titleLine?: string;
|
||||
tleLine1?: string;
|
||||
tleLine2?: string;
|
||||
updateIntervalInMs?: number;
|
||||
}
|
||||
|
||||
// @public
|
||||
export type SpacecraftsCreateOrUpdateResponse = Spacecraft;
|
||||
|
||||
// @public
|
||||
export interface SpacecraftsDeleteOptionalParams extends coreClient.OperationOptions {
|
||||
resumeFrom?: string;
|
||||
updateIntervalInMs?: number;
|
||||
}
|
||||
|
||||
// @public
|
||||
export interface SpacecraftsGetOptionalParams extends coreClient.OperationOptions {
|
||||
}
|
||||
|
||||
// @public
|
||||
export type SpacecraftsGetResponse = Spacecraft;
|
||||
|
||||
// @public
|
||||
export interface SpacecraftsListAvailableContactsOptionalParams extends coreClient.OperationOptions {
|
||||
resumeFrom?: string;
|
||||
updateIntervalInMs?: number;
|
||||
}
|
||||
|
||||
// @public
|
||||
export type SpacecraftsListAvailableContactsResponse = AvailableContactsListResult;
|
||||
|
||||
// @public
|
||||
export interface SpacecraftsListBySubscriptionOptionalParams extends coreClient.OperationOptions {
|
||||
}
|
||||
|
||||
// @public
|
||||
export type SpacecraftsListBySubscriptionResponse = SpacecraftListResult;
|
||||
|
||||
// @public
|
||||
export interface SpacecraftsListOptionalParams extends coreClient.OperationOptions {
|
||||
}
|
||||
|
||||
// @public
|
||||
export type SpacecraftsListResponse = SpacecraftListResult;
|
||||
|
||||
// @public
|
||||
export interface SpacecraftsUpdateTagsOptionalParams extends coreClient.OperationOptions {
|
||||
}
|
||||
|
||||
// @public
|
||||
export type SpacecraftsUpdateTagsResponse = Spacecraft;
|
||||
|
||||
// @public
|
||||
export type Status = "scheduled" | "cancelled" | "succeeded" | "failed" | "providerCancelled";
|
||||
|
||||
// @public
|
||||
export interface SystemData {
|
||||
createdAt?: Date;
|
||||
createdBy?: string;
|
||||
createdByType?: CreatedByType;
|
||||
lastModifiedAt?: Date;
|
||||
lastModifiedBy?: string;
|
||||
lastModifiedByType?: CreatedByType;
|
||||
}
|
||||
|
||||
// @public
|
||||
export interface TagsObject {
|
||||
tags?: {
|
||||
[propertyName: string]: string;
|
||||
};
|
||||
}
|
||||
|
||||
// @public
|
||||
export type TrackedResource = Resource & {
|
||||
tags?: {
|
||||
[propertyName: string]: string;
|
||||
};
|
||||
location: string;
|
||||
};
|
||||
|
||||
// (No @packageDocumentation comment for this package)
|
||||
|
||||
```
|
|
@ -0,0 +1,188 @@
|
|||
/*
|
||||
* Copyright (c) Microsoft Corporation.
|
||||
* Licensed under the MIT License.
|
||||
*
|
||||
* Code generated by Microsoft (R) AutoRest Code Generator.
|
||||
* Changes may cause incorrect behavior and will be lost if the code is regenerated.
|
||||
*/
|
||||
|
||||
import nodeResolve from "@rollup/plugin-node-resolve";
|
||||
import cjs from "@rollup/plugin-commonjs";
|
||||
import sourcemaps from "rollup-plugin-sourcemaps";
|
||||
import multiEntry from "@rollup/plugin-multi-entry";
|
||||
import json from "@rollup/plugin-json";
|
||||
|
||||
import nodeBuiltins from "builtin-modules";
|
||||
|
||||
/**
|
||||
* Gets the proper configuration needed for rollup's commonJS plugin for @opentelemetry/api.
|
||||
*
|
||||
* NOTE: this manual configuration is only needed because OpenTelemetry uses an
|
||||
* __exportStar downleveled helper function to declare its exports which confuses
|
||||
* rollup's automatic discovery mechanism.
|
||||
*
|
||||
* @returns an object reference that can be `...`'d into your cjs() configuration.
|
||||
*/
|
||||
export function openTelemetryCommonJs() {
|
||||
const namedExports = {};
|
||||
|
||||
for (const key of [
|
||||
"@opentelemetry/api",
|
||||
"@azure/core-tracing/node_modules/@opentelemetry/api"
|
||||
]) {
|
||||
namedExports[key] = [
|
||||
"SpanKind",
|
||||
"TraceFlags",
|
||||
"getSpan",
|
||||
"setSpan",
|
||||
"SpanStatusCode",
|
||||
"getSpanContext",
|
||||
"setSpanContext"
|
||||
];
|
||||
}
|
||||
|
||||
const releasedOpenTelemetryVersions = ["0.10.2", "1.0.0-rc.0"];
|
||||
|
||||
for (const version of releasedOpenTelemetryVersions) {
|
||||
namedExports[
|
||||
// working around a limitation in the rollup common.js plugin - it's not able to resolve these modules so the named exports listed above will not get applied. We have to drill down to the actual path.
|
||||
`../../../common/temp/node_modules/.pnpm/@opentelemetry/api@${version}/node_modules/@opentelemetry/api/build/src/index.js`
|
||||
] = [
|
||||
"SpanKind",
|
||||
"TraceFlags",
|
||||
"getSpan",
|
||||
"setSpan",
|
||||
"StatusCode",
|
||||
"CanonicalCode",
|
||||
"getSpanContext",
|
||||
"setSpanContext"
|
||||
];
|
||||
}
|
||||
|
||||
return namedExports;
|
||||
}
|
||||
|
||||
// #region Warning Handler
|
||||
|
||||
/**
|
||||
* A function that can determine whether a rollupwarning should be ignored. If
|
||||
* the function returns `true`, then the warning will not be displayed.
|
||||
*/
|
||||
|
||||
function ignoreNiseSinonEvalWarnings(warning) {
|
||||
return (
|
||||
warning.code === "EVAL" &&
|
||||
warning.id &&
|
||||
(warning.id.includes("node_modules/nise") ||
|
||||
warning.id.includes("node_modules/sinon")) === true
|
||||
);
|
||||
}
|
||||
|
||||
function ignoreChaiCircularDependencyWarnings(warning) {
|
||||
return (
|
||||
warning.code === "CIRCULAR_DEPENDENCY" &&
|
||||
warning.importer && warning.importer.includes("node_modules/chai") === true
|
||||
);
|
||||
}
|
||||
|
||||
const warningInhibitors = [
|
||||
ignoreChaiCircularDependencyWarnings,
|
||||
ignoreNiseSinonEvalWarnings
|
||||
];
|
||||
|
||||
/**
|
||||
* Construct a warning handler for the shared rollup configuration
|
||||
* that ignores certain warnings that are not relevant to testing.
|
||||
*/
|
||||
function makeOnWarnForTesting() {
|
||||
return (warning, warn) => {
|
||||
// If every inhibitor returns false (i.e. no inhibitors), then show the warning
|
||||
if (warningInhibitors.every((inhib) => !inhib(warning))) {
|
||||
warn(warning);
|
||||
}
|
||||
};
|
||||
}
|
||||
|
||||
// #endregion
|
||||
|
||||
function makeBrowserTestConfig() {
|
||||
const config = {
|
||||
input: {
|
||||
include: ["dist-esm/test/**/*.spec.js"],
|
||||
exclude: ["dist-esm/test/**/node/**"]
|
||||
},
|
||||
output: {
|
||||
file: `dist-test/index.browser.js`,
|
||||
format: "umd",
|
||||
sourcemap: true
|
||||
},
|
||||
preserveSymlinks: false,
|
||||
plugins: [
|
||||
multiEntry({ exports: false }),
|
||||
nodeResolve({
|
||||
mainFields: ["module", "browser"]
|
||||
}),
|
||||
cjs({
|
||||
namedExports: {
|
||||
// Chai's strange internal architecture makes it impossible to statically
|
||||
// analyze its exports.
|
||||
chai: [
|
||||
"version",
|
||||
"use",
|
||||
"util",
|
||||
"config",
|
||||
"expect",
|
||||
"should",
|
||||
"assert"
|
||||
],
|
||||
...openTelemetryCommonJs()
|
||||
}
|
||||
}),
|
||||
json(),
|
||||
sourcemaps()
|
||||
//viz({ filename: "dist-test/browser-stats.html", sourcemap: true })
|
||||
],
|
||||
onwarn: makeOnWarnForTesting(),
|
||||
// Disable tree-shaking of test code. In rollup-plugin-node-resolve@5.0.0,
|
||||
// rollup started respecting the "sideEffects" field in package.json. Since
|
||||
// our package.json sets "sideEffects=false", this also applies to test
|
||||
// code, which causes all tests to be removed by tree-shaking.
|
||||
treeshake: false
|
||||
};
|
||||
|
||||
return config;
|
||||
}
|
||||
|
||||
const defaultConfigurationOptions = {
|
||||
disableBrowserBundle: false
|
||||
};
|
||||
|
||||
export function makeConfig(pkg, options) {
|
||||
options = {
|
||||
...defaultConfigurationOptions,
|
||||
...(options || {})
|
||||
};
|
||||
|
||||
const baseConfig = {
|
||||
// Use the package's module field if it has one
|
||||
input: pkg["module"] || "dist-esm/src/index.js",
|
||||
external: [
|
||||
...nodeBuiltins,
|
||||
...Object.keys(pkg.dependencies),
|
||||
...Object.keys(pkg.devDependencies)
|
||||
],
|
||||
output: { file: "dist/index.js", format: "cjs", sourcemap: true },
|
||||
preserveSymlinks: false,
|
||||
plugins: [sourcemaps(), nodeResolve(), cjs()]
|
||||
};
|
||||
|
||||
const config = [baseConfig];
|
||||
|
||||
if (!options.disableBrowserBundle) {
|
||||
config.push(makeBrowserTestConfig());
|
||||
}
|
||||
|
||||
return config;
|
||||
}
|
||||
|
||||
export default makeConfig(require("./package.json"));
|
|
@ -0,0 +1,52 @@
|
|||
/*
|
||||
* Copyright (c) Microsoft Corporation.
|
||||
* Licensed under the MIT License.
|
||||
*
|
||||
* Code generated by Microsoft (R) AutoRest Code Generator.
|
||||
* Changes may cause incorrect behavior and will be lost if the code is regenerated.
|
||||
*/
|
||||
|
||||
import * as coreAuth from "@azure/core-auth";
|
||||
import {
|
||||
OperationsImpl,
|
||||
SpacecraftsImpl,
|
||||
ContactsImpl,
|
||||
ContactProfilesImpl,
|
||||
AvailableGroundStationsImpl
|
||||
} from "./operations";
|
||||
import {
|
||||
Operations,
|
||||
Spacecrafts,
|
||||
Contacts,
|
||||
ContactProfiles,
|
||||
AvailableGroundStations
|
||||
} from "./operationsInterfaces";
|
||||
import { AzureOrbitalContext } from "./azureOrbitalContext";
|
||||
import { AzureOrbitalOptionalParams } from "./models";
|
||||
|
||||
export class AzureOrbital extends AzureOrbitalContext {
|
||||
/**
|
||||
* Initializes a new instance of the AzureOrbital class.
|
||||
* @param credentials Subscription credentials which uniquely identify client subscription.
|
||||
* @param subscriptionId The ID of the target subscription.
|
||||
* @param options The parameter options
|
||||
*/
|
||||
constructor(
|
||||
credentials: coreAuth.TokenCredential,
|
||||
subscriptionId: string,
|
||||
options?: AzureOrbitalOptionalParams
|
||||
) {
|
||||
super(credentials, subscriptionId, options);
|
||||
this.operations = new OperationsImpl(this);
|
||||
this.spacecrafts = new SpacecraftsImpl(this);
|
||||
this.contacts = new ContactsImpl(this);
|
||||
this.contactProfiles = new ContactProfilesImpl(this);
|
||||
this.availableGroundStations = new AvailableGroundStationsImpl(this);
|
||||
}
|
||||
|
||||
operations: Operations;
|
||||
spacecrafts: Spacecrafts;
|
||||
contacts: Contacts;
|
||||
contactProfiles: ContactProfiles;
|
||||
availableGroundStations: AvailableGroundStations;
|
||||
}
|
|
@ -0,0 +1,70 @@
|
|||
/*
|
||||
* Copyright (c) Microsoft Corporation.
|
||||
* Licensed under the MIT License.
|
||||
*
|
||||
* Code generated by Microsoft (R) AutoRest Code Generator.
|
||||
* Changes may cause incorrect behavior and will be lost if the code is regenerated.
|
||||
*/
|
||||
|
||||
import * as coreClient from "@azure/core-client";
|
||||
import * as coreAuth from "@azure/core-auth";
|
||||
import { AzureOrbitalOptionalParams } from "./models";
|
||||
|
||||
export class AzureOrbitalContext extends coreClient.ServiceClient {
|
||||
$host: string;
|
||||
apiVersion: string;
|
||||
subscriptionId: string;
|
||||
|
||||
/**
|
||||
* Initializes a new instance of the AzureOrbitalContext class.
|
||||
* @param credentials Subscription credentials which uniquely identify client subscription.
|
||||
* @param subscriptionId The ID of the target subscription.
|
||||
* @param options The parameter options
|
||||
*/
|
||||
constructor(
|
||||
credentials: coreAuth.TokenCredential,
|
||||
subscriptionId: string,
|
||||
options?: AzureOrbitalOptionalParams
|
||||
) {
|
||||
if (credentials === undefined) {
|
||||
throw new Error("'credentials' cannot be null");
|
||||
}
|
||||
if (subscriptionId === undefined) {
|
||||
throw new Error("'subscriptionId' cannot be null");
|
||||
}
|
||||
|
||||
// Initializing default values for options
|
||||
if (!options) {
|
||||
options = {};
|
||||
}
|
||||
const defaults: AzureOrbitalOptionalParams = {
|
||||
requestContentType: "application/json; charset=utf-8",
|
||||
credential: credentials
|
||||
};
|
||||
|
||||
const packageDetails = `azsdk-js-arm-orbital/1.0.0-beta.1`;
|
||||
const userAgentPrefix =
|
||||
options.userAgentOptions && options.userAgentOptions.userAgentPrefix
|
||||
? `${options.userAgentOptions.userAgentPrefix} ${packageDetails}`
|
||||
: `${packageDetails}`;
|
||||
|
||||
if (!options.credentialScopes) {
|
||||
options.credentialScopes = ["https://management.azure.com/.default"];
|
||||
}
|
||||
const optionsWithDefaults = {
|
||||
...defaults,
|
||||
...options,
|
||||
userAgentOptions: {
|
||||
userAgentPrefix
|
||||
},
|
||||
baseUri: options.endpoint || "https://management.azure.com"
|
||||
};
|
||||
super(optionsWithDefaults);
|
||||
// Parameter assignments
|
||||
this.subscriptionId = subscriptionId;
|
||||
|
||||
// Assigning values to Constant parameters
|
||||
this.$host = options.$host || "https://management.azure.com";
|
||||
this.apiVersion = options.apiVersion || "2021-04-04-preview";
|
||||
}
|
||||
}
|
|
@ -0,0 +1,13 @@
|
|||
/*
|
||||
* Copyright (c) Microsoft Corporation.
|
||||
* Licensed under the MIT License.
|
||||
*
|
||||
* Code generated by Microsoft (R) AutoRest Code Generator.
|
||||
* Changes may cause incorrect behavior and will be lost if the code is regenerated.
|
||||
*/
|
||||
|
||||
/// <reference lib="esnext.asynciterable" />
|
||||
export * from "./models";
|
||||
export { AzureOrbital } from "./azureOrbital";
|
||||
export { AzureOrbitalContext } from "./azureOrbitalContext";
|
||||
export * from "./operationsInterfaces";
|
|
@ -0,0 +1,34 @@
|
|||
/*
|
||||
* Copyright (c) Microsoft Corporation.
|
||||
* Licensed under the MIT License.
|
||||
*
|
||||
* Code generated by Microsoft (R) AutoRest Code Generator.
|
||||
* Changes may cause incorrect behavior and will be lost if the code is regenerated.
|
||||
*/
|
||||
|
||||
import { LongRunningOperation, LroResponse } from "@azure/core-lro";
|
||||
|
||||
export class LroImpl<T> implements LongRunningOperation<T> {
|
||||
constructor(
|
||||
private sendOperationFn: (args: any, spec: any) => Promise<LroResponse<T>>,
|
||||
private args: Record<string, unknown>,
|
||||
private spec: {
|
||||
readonly requestBody?: unknown;
|
||||
readonly path?: string;
|
||||
readonly httpMethod: string;
|
||||
} & Record<string, any>,
|
||||
public requestPath: string = spec.path!,
|
||||
public requestMethod: string = spec.httpMethod
|
||||
) {}
|
||||
public async sendInitialRequest(): Promise<LroResponse<T>> {
|
||||
return this.sendOperationFn(this.args, this.spec);
|
||||
}
|
||||
public async sendPollRequest(path: string): Promise<LroResponse<T>> {
|
||||
const { requestBody, ...restSpec } = this.spec;
|
||||
return this.sendOperationFn(this.args, {
|
||||
...restSpec,
|
||||
path,
|
||||
httpMethod: "GET"
|
||||
});
|
||||
}
|
||||
}
|
|
@ -0,0 +1,853 @@
|
|||
/*
|
||||
* Copyright (c) Microsoft Corporation.
|
||||
* Licensed under the MIT License.
|
||||
*
|
||||
* Code generated by Microsoft (R) AutoRest Code Generator.
|
||||
* Changes may cause incorrect behavior and will be lost if the code is regenerated.
|
||||
*/
|
||||
|
||||
import * as coreClient from "@azure/core-client";
|
||||
|
||||
/** A list of REST API operations supported by an Azure Resource Provider. It contains an URL link to get the next set of results. */
|
||||
export interface OperationListResult {
|
||||
/**
|
||||
* List of operations supported by the resource provider
|
||||
* NOTE: This property will not be serialized. It can only be populated by the server.
|
||||
*/
|
||||
readonly value?: Operation[];
|
||||
/**
|
||||
* URL to get the next set of operation list results (if there are any).
|
||||
* NOTE: This property will not be serialized. It can only be populated by the server.
|
||||
*/
|
||||
readonly nextLink?: string;
|
||||
}
|
||||
|
||||
/** Details of a REST API operation, returned from the Resource Provider Operations API */
|
||||
export interface Operation {
|
||||
/**
|
||||
* The name of the operation, as per Resource-Based Access Control (RBAC). Examples: "Microsoft.Compute/virtualMachines/write", "Microsoft.Compute/virtualMachines/capture/action"
|
||||
* NOTE: This property will not be serialized. It can only be populated by the server.
|
||||
*/
|
||||
readonly name?: string;
|
||||
/**
|
||||
* Whether the operation applies to data-plane. This is "true" for data-plane operations and "false" for ARM/control-plane operations.
|
||||
* NOTE: This property will not be serialized. It can only be populated by the server.
|
||||
*/
|
||||
readonly isDataAction?: boolean;
|
||||
/** Localized display information for this particular operation. */
|
||||
display?: OperationDisplay;
|
||||
/**
|
||||
* The intended executor of the operation; as in Resource Based Access Control (RBAC) and audit logs UX. Default value is "user,system"
|
||||
* NOTE: This property will not be serialized. It can only be populated by the server.
|
||||
*/
|
||||
readonly origin?: Origin;
|
||||
/**
|
||||
* Enum. Indicates the action type. "Internal" refers to actions that are for internal only APIs.
|
||||
* NOTE: This property will not be serialized. It can only be populated by the server.
|
||||
*/
|
||||
readonly actionType?: ActionType;
|
||||
}
|
||||
|
||||
/** Localized display information for this particular operation. */
|
||||
export interface OperationDisplay {
|
||||
/**
|
||||
* The localized friendly form of the resource provider name, e.g. "Microsoft Monitoring Insights" or "Microsoft Compute".
|
||||
* NOTE: This property will not be serialized. It can only be populated by the server.
|
||||
*/
|
||||
readonly provider?: string;
|
||||
/**
|
||||
* The localized friendly name of the resource type related to this operation. E.g. "Virtual Machines" or "Job Schedule Collections".
|
||||
* NOTE: This property will not be serialized. It can only be populated by the server.
|
||||
*/
|
||||
readonly resource?: string;
|
||||
/**
|
||||
* The concise, localized friendly name for the operation; suitable for dropdowns. E.g. "Create or Update Virtual Machine", "Restart Virtual Machine".
|
||||
* NOTE: This property will not be serialized. It can only be populated by the server.
|
||||
*/
|
||||
readonly operation?: string;
|
||||
/**
|
||||
* The short, localized friendly description of the operation; suitable for tool tips and detailed views.
|
||||
* NOTE: This property will not be serialized. It can only be populated by the server.
|
||||
*/
|
||||
readonly description?: string;
|
||||
}
|
||||
|
||||
/** An error response from the service. */
|
||||
export interface CloudError {
|
||||
/** An error response from the service. */
|
||||
error?: CloudErrorBody;
|
||||
}
|
||||
|
||||
/** An error response from the service. */
|
||||
export interface CloudErrorBody {
|
||||
/** An identifier for the error. Codes are invariant and are intended to be consumed programmatically. */
|
||||
code?: string;
|
||||
/** A message describing the error, intended to be suitable for display in a user interface. */
|
||||
message?: string;
|
||||
/** The target of the particular error. For example, the name of the property in error. */
|
||||
target?: string;
|
||||
/** A list of additional details about the error. */
|
||||
details?: CloudErrorBody[];
|
||||
}
|
||||
|
||||
/** Response for the ListSpacecrafts API service call. */
|
||||
export interface SpacecraftListResult {
|
||||
/** A list of spacecraft resources in a resource group. */
|
||||
value?: Spacecraft[];
|
||||
/**
|
||||
* The URL to get the next set of results.
|
||||
* NOTE: This property will not be serialized. It can only be populated by the server.
|
||||
*/
|
||||
readonly nextLink?: string;
|
||||
}
|
||||
|
||||
/** Spacecraft Link */
|
||||
export interface SpacecraftLink {
|
||||
/** Center Frequency in MHz */
|
||||
centerFrequencyMHz: number;
|
||||
/** Bandwidth in MHz */
|
||||
bandwidthMHz: number;
|
||||
/** Direction (uplink or downlink) */
|
||||
direction: Direction;
|
||||
/** polarization. eg (RHCP, LHCP) */
|
||||
polarization: Polarization;
|
||||
}
|
||||
|
||||
/** Common fields that are returned in the response for all Azure Resource Manager resources */
|
||||
export interface Resource {
|
||||
/**
|
||||
* Fully qualified resource ID for the resource. Ex - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName}
|
||||
* NOTE: This property will not be serialized. It can only be populated by the server.
|
||||
*/
|
||||
readonly id?: string;
|
||||
/**
|
||||
* The name of the resource
|
||||
* NOTE: This property will not be serialized. It can only be populated by the server.
|
||||
*/
|
||||
readonly name?: string;
|
||||
/**
|
||||
* The type of the resource. E.g. "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts"
|
||||
* NOTE: This property will not be serialized. It can only be populated by the server.
|
||||
*/
|
||||
readonly type?: string;
|
||||
/**
|
||||
* Azure Resource Manager metadata containing createdBy and modifiedBy information.
|
||||
* NOTE: This property will not be serialized. It can only be populated by the server.
|
||||
*/
|
||||
readonly systemData?: SystemData;
|
||||
}
|
||||
|
||||
/** Metadata pertaining to creation and last modification of the resource. */
|
||||
export interface SystemData {
|
||||
/** The identity that created the resource. */
|
||||
createdBy?: string;
|
||||
/** The type of identity that created the resource. */
|
||||
createdByType?: CreatedByType;
|
||||
/** The timestamp of resource creation (UTC). */
|
||||
createdAt?: Date;
|
||||
/** The identity that last modified the resource. */
|
||||
lastModifiedBy?: string;
|
||||
/** The type of identity that last modified the resource. */
|
||||
lastModifiedByType?: CreatedByType;
|
||||
/** The timestamp of resource last modification (UTC) */
|
||||
lastModifiedAt?: Date;
|
||||
}
|
||||
|
||||
/** Tags object for patch operations. */
|
||||
export interface TagsObject {
|
||||
/** Resource tags. */
|
||||
tags?: { [propertyName: string]: string };
|
||||
}
|
||||
|
||||
/** Response for the ListContacts API service call. */
|
||||
export interface ContactListResult {
|
||||
/** A list of contact resources in a resource group. */
|
||||
value?: Contact[];
|
||||
/**
|
||||
* The URL to get the next set of results.
|
||||
* NOTE: This property will not be serialized. It can only be populated by the server.
|
||||
*/
|
||||
readonly nextLink?: string;
|
||||
}
|
||||
|
||||
/** Resource Reference */
|
||||
export interface ResourceReference {
|
||||
/** Resource ID. */
|
||||
id?: string;
|
||||
}
|
||||
|
||||
/** Parameters that define the contact resource. */
|
||||
export interface ContactParameters {
|
||||
/** The reference to the contact profile resource. */
|
||||
contactProfile: ResourceReference;
|
||||
/** Name of Azure Ground Station. */
|
||||
groundStationName: string;
|
||||
/** Start time of a contact. */
|
||||
startTime: Date;
|
||||
/** End time of a contact. */
|
||||
endTime: Date;
|
||||
}
|
||||
|
||||
/** Response for the ListAvailableContacts API service call. */
|
||||
export interface AvailableContactsListResult {
|
||||
/** A list of available contacts */
|
||||
value?: AvailableContacts[];
|
||||
/**
|
||||
* The URL to get the next set of results.
|
||||
* NOTE: This property will not be serialized. It can only be populated by the server.
|
||||
*/
|
||||
readonly nextLink?: string;
|
||||
}
|
||||
|
||||
/** Customer retrieves list of Available Contacts for a spacecraft resource. Later, one of the available contact can be selected to create a contact. */
|
||||
export interface AvailableContacts {
|
||||
/** The reference to the spacecraft resource. */
|
||||
spacecraft?: ResourceReference;
|
||||
/**
|
||||
* Name of Azure Ground Station.
|
||||
* NOTE: This property will not be serialized. It can only be populated by the server.
|
||||
*/
|
||||
readonly groundStationName?: string;
|
||||
/**
|
||||
* Maximum elevation of the antenna during the contact in decimal degrees.
|
||||
* NOTE: This property will not be serialized. It can only be populated by the server.
|
||||
*/
|
||||
readonly maximumElevationDegrees?: number;
|
||||
/**
|
||||
* Time at which antenna transmit will be enabled.
|
||||
* NOTE: This property will not be serialized. It can only be populated by the server.
|
||||
*/
|
||||
readonly txStartTime?: Date;
|
||||
/**
|
||||
* Time at which antenna transmit will be disabled.
|
||||
* NOTE: This property will not be serialized. It can only be populated by the server.
|
||||
*/
|
||||
readonly txEndTime?: Date;
|
||||
/**
|
||||
* Earliest time to receive a signal.
|
||||
* NOTE: This property will not be serialized. It can only be populated by the server.
|
||||
*/
|
||||
readonly rxStartTime?: Date;
|
||||
/**
|
||||
* Time to lost receiving a signal.
|
||||
* NOTE: This property will not be serialized. It can only be populated by the server.
|
||||
*/
|
||||
readonly rxEndTime?: Date;
|
||||
/**
|
||||
* Azimuth of the antenna at the start of the contact in decimal degrees.
|
||||
* NOTE: This property will not be serialized. It can only be populated by the server.
|
||||
*/
|
||||
readonly startAzimuthDegrees?: number;
|
||||
/**
|
||||
* Azimuth of the antenna at the end of the contact in decimal degrees.
|
||||
* NOTE: This property will not be serialized. It can only be populated by the server.
|
||||
*/
|
||||
readonly endAzimuthDegrees?: number;
|
||||
/**
|
||||
* Spacecraft elevation above the horizon at contact start.
|
||||
* NOTE: This property will not be serialized. It can only be populated by the server.
|
||||
*/
|
||||
readonly startElevationDegrees?: number;
|
||||
/**
|
||||
* Spacecraft elevation above the horizon at contact end.
|
||||
* NOTE: This property will not be serialized. It can only be populated by the server.
|
||||
*/
|
||||
readonly endElevationDegrees?: number;
|
||||
}
|
||||
|
||||
/** Contact Profile link */
|
||||
export interface ContactProfileLink {
|
||||
/** polarization. eg (RHCP, LHCP) */
|
||||
polarization: Polarization;
|
||||
/** Direction (uplink or downlink) */
|
||||
direction: Direction;
|
||||
/** Gain To Noise Temperature in db/K. */
|
||||
gainOverTemperature?: number;
|
||||
/** Effective Isotropic Radiated Power (EIRP) in dBW. */
|
||||
eirpdBW?: number;
|
||||
/** Contact Profile Link Channel */
|
||||
channels: ContactProfileLinkChannel[];
|
||||
}
|
||||
|
||||
/** Contact Profile Link Channel */
|
||||
export interface ContactProfileLinkChannel {
|
||||
/** Center Frequency in MHz */
|
||||
centerFrequencyMHz: number;
|
||||
/** Bandwidth in MHz */
|
||||
bandwidthMHz: number;
|
||||
/** Customer End point to store/retrieve data during a contact. */
|
||||
endPoint: EndPoint;
|
||||
/** Configuration for modulation */
|
||||
modulationConfiguration?: string;
|
||||
/** Configuration for demodulation */
|
||||
demodulationConfiguration?: string;
|
||||
/** Configuration for encoding */
|
||||
encodingConfiguration?: string;
|
||||
/** Configuration for decoding */
|
||||
decodingConfiguration?: string;
|
||||
}
|
||||
|
||||
/** Customer End point to store/retrieve data during a contact. */
|
||||
export interface EndPoint {
|
||||
/** IP Address. */
|
||||
ipAddress: string;
|
||||
/** Name of an end point. */
|
||||
endPointName: string;
|
||||
/** TCP port to listen on to receive data. */
|
||||
port: string;
|
||||
/** Protocol either UDP or TCP. */
|
||||
protocol: Protocol;
|
||||
}
|
||||
|
||||
/** Response for the ListContactProfiles API service call. */
|
||||
export interface ContactProfileListResult {
|
||||
/** A list of contact profile resources in a resource group. */
|
||||
value?: ContactProfile[];
|
||||
/**
|
||||
* The URL to get the next set of results.
|
||||
* NOTE: This property will not be serialized. It can only be populated by the server.
|
||||
*/
|
||||
readonly nextLink?: string;
|
||||
}
|
||||
|
||||
/** Response for the AvailableGroundStations API service call. */
|
||||
export interface AvailableGroundStationListResult {
|
||||
/** A list of ground station resources. */
|
||||
value?: AvailableGroundStation[];
|
||||
/**
|
||||
* The URL to get the next set of results.
|
||||
* NOTE: This property will not be serialized. It can only be populated by the server.
|
||||
*/
|
||||
readonly nextLink?: string;
|
||||
}
|
||||
|
||||
/** GroundStations available to schedule Contacts */
|
||||
export interface AvailableGroundStation {
|
||||
/**
|
||||
* Id of groundStation
|
||||
* NOTE: This property will not be serialized. It can only be populated by the server.
|
||||
*/
|
||||
readonly id?: string;
|
||||
/**
|
||||
* Name of the ground station.
|
||||
* NOTE: This property will not be serialized. It can only be populated by the server.
|
||||
*/
|
||||
readonly name?: string;
|
||||
/** Azure region */
|
||||
location?: string;
|
||||
/**
|
||||
* Resource type.
|
||||
* NOTE: This property will not be serialized. It can only be populated by the server.
|
||||
*/
|
||||
readonly type?: string;
|
||||
/** City of ground station. */
|
||||
city?: string;
|
||||
/** Ground station provider name. */
|
||||
providerName?: string;
|
||||
/** Longitude of the ground station in decimal degrees. */
|
||||
longitudeDegrees?: number;
|
||||
/** Latitude of the ground station in decimal degrees. */
|
||||
latitudeDegrees?: number;
|
||||
/** Altitude of the ground station */
|
||||
altitudeMeters?: number;
|
||||
}
|
||||
|
||||
/** Response for an API service call that lists the resource IDs of resources associated with another resource. */
|
||||
export interface ResourceIdListResult {
|
||||
/** A list of Azure Resource IDs. */
|
||||
value?: ResourceIdListResultValueItem[];
|
||||
/**
|
||||
* The URL to get the next set of results.
|
||||
* NOTE: This property will not be serialized. It can only be populated by the server.
|
||||
*/
|
||||
readonly nextLink?: string;
|
||||
}
|
||||
|
||||
export interface ResourceIdListResultValueItem {
|
||||
/** The Azure Resource ID */
|
||||
id?: string;
|
||||
}
|
||||
|
||||
/** The resource model definition for an Azure Resource Manager tracked top level resource which has 'tags' and a 'location' */
|
||||
export type TrackedResource = Resource & {
|
||||
/** Resource tags. */
|
||||
tags?: { [propertyName: string]: string };
|
||||
/** The geo-location where the resource lives */
|
||||
location: string;
|
||||
};
|
||||
|
||||
/** The resource model definition for a Azure Resource Manager proxy resource. It will not have tags and a location */
|
||||
export type ProxyResource = Resource & {};
|
||||
|
||||
/** Customer creates a spacecraft resource to schedule a contact. */
|
||||
export type Spacecraft = TrackedResource & {
|
||||
/**
|
||||
* A unique read-only string that changes whenever the resource is updated.
|
||||
* NOTE: This property will not be serialized. It can only be populated by the server.
|
||||
*/
|
||||
readonly etag?: string;
|
||||
/** NORAD ID of the spacecraft. */
|
||||
noradId?: string;
|
||||
/**
|
||||
* Authorization status of spacecraft.
|
||||
* NOTE: This property will not be serialized. It can only be populated by the server.
|
||||
*/
|
||||
readonly authorizationStatus?: AuthorizationStatus;
|
||||
/**
|
||||
* Details of the authorization status.
|
||||
* NOTE: This property will not be serialized. It can only be populated by the server.
|
||||
*/
|
||||
readonly authorizationStatusExtended?: string;
|
||||
/** Title line of Two Line Element (TLE). */
|
||||
titleLine?: string;
|
||||
/** Line 1 of Two Line Element (TLE). */
|
||||
tleLine1?: string;
|
||||
/** Line 2 of Two Line Element (TLE). */
|
||||
tleLine2?: string;
|
||||
/** Links of the Spacecraft */
|
||||
links?: SpacecraftLink[];
|
||||
};
|
||||
|
||||
/** Customer creates a Contact Profile Resource, which will contain all of the configurations required for scheduling a contact. */
|
||||
export type ContactProfile = TrackedResource & {
|
||||
/**
|
||||
* A unique read-only string that changes whenever the resource is updated.
|
||||
* NOTE: This property will not be serialized. It can only be populated by the server.
|
||||
*/
|
||||
readonly etag?: string;
|
||||
/** Minimum viable contact duration in ISO 8601 format. */
|
||||
minimumViableContactDuration?: string;
|
||||
/** Minimum viable elevation for the contact in decimal degrees. */
|
||||
minimumElevationDegrees?: number;
|
||||
/** Auto track configuration. */
|
||||
autoTrackingConfiguration?: AutoTrackingConfiguration;
|
||||
/** Links of the Contact Profile */
|
||||
links?: ContactProfileLink[];
|
||||
};
|
||||
|
||||
/** Customer creates a contact resource for a spacecraft resource. */
|
||||
export type Contact = ProxyResource & {
|
||||
/**
|
||||
* A unique read-only string that changes whenever the resource is updated.
|
||||
* NOTE: This property will not be serialized. It can only be populated by the server.
|
||||
*/
|
||||
readonly etag?: string;
|
||||
/**
|
||||
* Status of a contact.
|
||||
* NOTE: This property will not be serialized. It can only be populated by the server.
|
||||
*/
|
||||
readonly status?: Status;
|
||||
/** Reservation start time of a contact. */
|
||||
reservationStartTime?: Date;
|
||||
/** Reservation end time of a contact. */
|
||||
reservationEndTime?: Date;
|
||||
/**
|
||||
* Receive start time of a contact.
|
||||
* NOTE: This property will not be serialized. It can only be populated by the server.
|
||||
*/
|
||||
readonly rxStartTime?: Date;
|
||||
/**
|
||||
* Receive end time of a contact.
|
||||
* NOTE: This property will not be serialized. It can only be populated by the server.
|
||||
*/
|
||||
readonly rxEndTime?: Date;
|
||||
/**
|
||||
* Transmit start time of a contact.
|
||||
* NOTE: This property will not be serialized. It can only be populated by the server.
|
||||
*/
|
||||
readonly txStartTime?: Date;
|
||||
/**
|
||||
* Transmit end time of a contact.
|
||||
* NOTE: This property will not be serialized. It can only be populated by the server.
|
||||
*/
|
||||
readonly txEndTime?: Date;
|
||||
/**
|
||||
* Any error message while scheduling a contact.
|
||||
* NOTE: This property will not be serialized. It can only be populated by the server.
|
||||
*/
|
||||
readonly errorMessage?: string;
|
||||
/**
|
||||
* Maximum elevation of the antenna during the contact in decimal degrees.
|
||||
* NOTE: This property will not be serialized. It can only be populated by the server.
|
||||
*/
|
||||
readonly maximumElevationDegrees?: number;
|
||||
/**
|
||||
* Azimuth of the antenna at the start of the contact in decimal degrees.
|
||||
* NOTE: This property will not be serialized. It can only be populated by the server.
|
||||
*/
|
||||
readonly startAzimuthDegrees?: number;
|
||||
/**
|
||||
* Azimuth of the antenna at the end of the contact in decimal degrees.
|
||||
* NOTE: This property will not be serialized. It can only be populated by the server.
|
||||
*/
|
||||
readonly endAzimuthDegrees?: number;
|
||||
/** Azure Ground Station name. */
|
||||
groundStationName?: string;
|
||||
/**
|
||||
* Spacecraft elevation above the horizon at contact start.
|
||||
* NOTE: This property will not be serialized. It can only be populated by the server.
|
||||
*/
|
||||
readonly startElevationDegrees?: number;
|
||||
/**
|
||||
* Spacecraft elevation above the horizon at contact end.
|
||||
* NOTE: This property will not be serialized. It can only be populated by the server.
|
||||
*/
|
||||
readonly endElevationDegrees?: number;
|
||||
/** The reference to the contact profile resource. */
|
||||
contactProfile?: ResourceReference;
|
||||
};
|
||||
|
||||
/** Known values of {@link Origin} that the service accepts. */
|
||||
export enum KnownOrigin {
|
||||
User = "user",
|
||||
System = "system",
|
||||
UserSystem = "user,system"
|
||||
}
|
||||
|
||||
/**
|
||||
* Defines values for Origin. \
|
||||
* {@link KnownOrigin} can be used interchangeably with Origin,
|
||||
* this enum contains the known values that the service supports.
|
||||
* ### Known values supported by the service
|
||||
* **user** \
|
||||
* **system** \
|
||||
* **user,system**
|
||||
*/
|
||||
export type Origin = string;
|
||||
|
||||
/** Known values of {@link ActionType} that the service accepts. */
|
||||
export enum KnownActionType {
|
||||
Internal = "Internal"
|
||||
}
|
||||
|
||||
/**
|
||||
* Defines values for ActionType. \
|
||||
* {@link KnownActionType} can be used interchangeably with ActionType,
|
||||
* this enum contains the known values that the service supports.
|
||||
* ### Known values supported by the service
|
||||
* **Internal**
|
||||
*/
|
||||
export type ActionType = string;
|
||||
|
||||
/** Known values of {@link Direction} that the service accepts. */
|
||||
export enum KnownDirection {
|
||||
Uplink = "uplink",
|
||||
Downlink = "downlink"
|
||||
}
|
||||
|
||||
/**
|
||||
* Defines values for Direction. \
|
||||
* {@link KnownDirection} can be used interchangeably with Direction,
|
||||
* this enum contains the known values that the service supports.
|
||||
* ### Known values supported by the service
|
||||
* **uplink** \
|
||||
* **downlink**
|
||||
*/
|
||||
export type Direction = string;
|
||||
|
||||
/** Known values of {@link Polarization} that the service accepts. */
|
||||
export enum KnownPolarization {
|
||||
Rhcp = "RHCP",
|
||||
Lhcp = "LHCP",
|
||||
DualRhcpLhcp = "dualRhcpLhcp",
|
||||
LinearVertical = "linearVertical",
|
||||
LinearHorizontal = "linearHorizontal"
|
||||
}
|
||||
|
||||
/**
|
||||
* Defines values for Polarization. \
|
||||
* {@link KnownPolarization} can be used interchangeably with Polarization,
|
||||
* this enum contains the known values that the service supports.
|
||||
* ### Known values supported by the service
|
||||
* **RHCP** \
|
||||
* **LHCP** \
|
||||
* **dualRhcpLhcp** \
|
||||
* **linearVertical** \
|
||||
* **linearHorizontal**
|
||||
*/
|
||||
export type Polarization = string;
|
||||
|
||||
/** Known values of {@link CreatedByType} that the service accepts. */
|
||||
export enum KnownCreatedByType {
|
||||
User = "User",
|
||||
Application = "Application",
|
||||
ManagedIdentity = "ManagedIdentity",
|
||||
Key = "Key"
|
||||
}
|
||||
|
||||
/**
|
||||
* Defines values for CreatedByType. \
|
||||
* {@link KnownCreatedByType} can be used interchangeably with CreatedByType,
|
||||
* this enum contains the known values that the service supports.
|
||||
* ### Known values supported by the service
|
||||
* **User** \
|
||||
* **Application** \
|
||||
* **ManagedIdentity** \
|
||||
* **Key**
|
||||
*/
|
||||
export type CreatedByType = string;
|
||||
|
||||
/** Known values of {@link Protocol} that the service accepts. */
|
||||
export enum KnownProtocol {
|
||||
TCP = "TCP",
|
||||
UDP = "UDP"
|
||||
}
|
||||
|
||||
/**
|
||||
* Defines values for Protocol. \
|
||||
* {@link KnownProtocol} can be used interchangeably with Protocol,
|
||||
* this enum contains the known values that the service supports.
|
||||
* ### Known values supported by the service
|
||||
* **TCP** \
|
||||
* **UDP**
|
||||
*/
|
||||
export type Protocol = string;
|
||||
|
||||
/** Known values of {@link Enum6} that the service accepts. */
|
||||
export enum KnownEnum6 {
|
||||
EarthObservation = "EarthObservation",
|
||||
Communication = "Communication"
|
||||
}
|
||||
|
||||
/**
|
||||
* Defines values for Enum6. \
|
||||
* {@link KnownEnum6} can be used interchangeably with Enum6,
|
||||
* this enum contains the known values that the service supports.
|
||||
* ### Known values supported by the service
|
||||
* **EarthObservation** \
|
||||
* **Communication**
|
||||
*/
|
||||
export type Enum6 = string;
|
||||
|
||||
/** Known values of {@link Capability} that the service accepts. */
|
||||
export enum KnownCapability {
|
||||
EarthObservation = "EarthObservation",
|
||||
Communication = "Communication"
|
||||
}
|
||||
|
||||
/**
|
||||
* Defines values for Capability. \
|
||||
* {@link KnownCapability} can be used interchangeably with Capability,
|
||||
* this enum contains the known values that the service supports.
|
||||
* ### Known values supported by the service
|
||||
* **EarthObservation** \
|
||||
* **Communication**
|
||||
*/
|
||||
export type Capability = string;
|
||||
/** Defines values for AuthorizationStatus. */
|
||||
export type AuthorizationStatus = "Allowed" | "Pending" | "Denied";
|
||||
/** Defines values for Status. */
|
||||
export type Status =
|
||||
| "scheduled"
|
||||
| "cancelled"
|
||||
| "succeeded"
|
||||
| "failed"
|
||||
| "providerCancelled";
|
||||
/** Defines values for AutoTrackingConfiguration. */
|
||||
export type AutoTrackingConfiguration = "disabled" | "xBand" | "sBand";
|
||||
|
||||
/** Optional parameters. */
|
||||
export interface OperationsListOptionalParams
|
||||
extends coreClient.OperationOptions {}
|
||||
|
||||
/** Contains response data for the list operation. */
|
||||
export type OperationsListResponse = OperationListResult;
|
||||
|
||||
/** Optional parameters. */
|
||||
export interface SpacecraftsListBySubscriptionOptionalParams
|
||||
extends coreClient.OperationOptions {}
|
||||
|
||||
/** Contains response data for the listBySubscription operation. */
|
||||
export type SpacecraftsListBySubscriptionResponse = SpacecraftListResult;
|
||||
|
||||
/** Optional parameters. */
|
||||
export interface SpacecraftsListOptionalParams
|
||||
extends coreClient.OperationOptions {}
|
||||
|
||||
/** Contains response data for the list operation. */
|
||||
export type SpacecraftsListResponse = SpacecraftListResult;
|
||||
|
||||
/** Optional parameters. */
|
||||
export interface SpacecraftsGetOptionalParams
|
||||
extends coreClient.OperationOptions {}
|
||||
|
||||
/** Contains response data for the get operation. */
|
||||
export type SpacecraftsGetResponse = Spacecraft;
|
||||
|
||||
/** Optional parameters. */
|
||||
export interface SpacecraftsCreateOrUpdateOptionalParams
|
||||
extends coreClient.OperationOptions {
|
||||
/** Resource tags. */
|
||||
tags?: { [propertyName: string]: string };
|
||||
/** NORAD ID of the spacecraft. */
|
||||
noradId?: string;
|
||||
/** Title line of Two Line Element (TLE). */
|
||||
titleLine?: string;
|
||||
/** Line 1 of Two Line Element (TLE). */
|
||||
tleLine1?: string;
|
||||
/** Line 2 of Two Line Element (TLE). */
|
||||
tleLine2?: string;
|
||||
/** Links of the Spacecraft */
|
||||
links?: SpacecraftLink[];
|
||||
/** Delay to wait until next poll, in milliseconds. */
|
||||
updateIntervalInMs?: number;
|
||||
/** A serialized poller which can be used to resume an existing paused Long-Running-Operation. */
|
||||
resumeFrom?: string;
|
||||
}
|
||||
|
||||
/** Contains response data for the createOrUpdate operation. */
|
||||
export type SpacecraftsCreateOrUpdateResponse = Spacecraft;
|
||||
|
||||
/** Optional parameters. */
|
||||
export interface SpacecraftsDeleteOptionalParams
|
||||
extends coreClient.OperationOptions {
|
||||
/** Delay to wait until next poll, in milliseconds. */
|
||||
updateIntervalInMs?: number;
|
||||
/** A serialized poller which can be used to resume an existing paused Long-Running-Operation. */
|
||||
resumeFrom?: string;
|
||||
}
|
||||
|
||||
/** Optional parameters. */
|
||||
export interface SpacecraftsUpdateTagsOptionalParams
|
||||
extends coreClient.OperationOptions {}
|
||||
|
||||
/** Contains response data for the updateTags operation. */
|
||||
export type SpacecraftsUpdateTagsResponse = Spacecraft;
|
||||
|
||||
/** Optional parameters. */
|
||||
export interface SpacecraftsListAvailableContactsOptionalParams
|
||||
extends coreClient.OperationOptions {
|
||||
/** Delay to wait until next poll, in milliseconds. */
|
||||
updateIntervalInMs?: number;
|
||||
/** A serialized poller which can be used to resume an existing paused Long-Running-Operation. */
|
||||
resumeFrom?: string;
|
||||
}
|
||||
|
||||
/** Contains response data for the listAvailableContacts operation. */
|
||||
export type SpacecraftsListAvailableContactsResponse = AvailableContactsListResult;
|
||||
|
||||
/** Optional parameters. */
|
||||
export interface ContactsListOptionalParams
|
||||
extends coreClient.OperationOptions {}
|
||||
|
||||
/** Contains response data for the list operation. */
|
||||
export type ContactsListResponse = ContactListResult;
|
||||
|
||||
/** Optional parameters. */
|
||||
export interface ContactsGetOptionalParams
|
||||
extends coreClient.OperationOptions {}
|
||||
|
||||
/** Contains response data for the get operation. */
|
||||
export type ContactsGetResponse = Contact;
|
||||
|
||||
/** Optional parameters. */
|
||||
export interface ContactsCreateOptionalParams
|
||||
extends coreClient.OperationOptions {
|
||||
/** Delay to wait until next poll, in milliseconds. */
|
||||
updateIntervalInMs?: number;
|
||||
/** A serialized poller which can be used to resume an existing paused Long-Running-Operation. */
|
||||
resumeFrom?: string;
|
||||
}
|
||||
|
||||
/** Contains response data for the create operation. */
|
||||
export type ContactsCreateResponse = Contact;
|
||||
|
||||
/** Optional parameters. */
|
||||
export interface ContactsDeleteOptionalParams
|
||||
extends coreClient.OperationOptions {
|
||||
/** Delay to wait until next poll, in milliseconds. */
|
||||
updateIntervalInMs?: number;
|
||||
/** A serialized poller which can be used to resume an existing paused Long-Running-Operation. */
|
||||
resumeFrom?: string;
|
||||
}
|
||||
|
||||
/** Optional parameters. */
|
||||
export interface ContactProfilesGetOptionalParams
|
||||
extends coreClient.OperationOptions {}
|
||||
|
||||
/** Contains response data for the get operation. */
|
||||
export type ContactProfilesGetResponse = ContactProfile;
|
||||
|
||||
/** Optional parameters. */
|
||||
export interface ContactProfilesCreateOrUpdateOptionalParams
|
||||
extends coreClient.OperationOptions {
|
||||
/** Resource tags. */
|
||||
tags?: { [propertyName: string]: string };
|
||||
/** Minimum viable contact duration in ISO 8601 format. */
|
||||
minimumViableContactDuration?: string;
|
||||
/** Minimum viable elevation for the contact in decimal degrees. */
|
||||
minimumElevationDegrees?: number;
|
||||
/** Auto track configuration. */
|
||||
autoTrackingConfiguration?: AutoTrackingConfiguration;
|
||||
/** Links of the Contact Profile */
|
||||
links?: ContactProfileLink[];
|
||||
/** Delay to wait until next poll, in milliseconds. */
|
||||
updateIntervalInMs?: number;
|
||||
/** A serialized poller which can be used to resume an existing paused Long-Running-Operation. */
|
||||
resumeFrom?: string;
|
||||
}
|
||||
|
||||
/** Contains response data for the createOrUpdate operation. */
|
||||
export type ContactProfilesCreateOrUpdateResponse = ContactProfile;
|
||||
|
||||
/** Optional parameters. */
|
||||
export interface ContactProfilesDeleteOptionalParams
|
||||
extends coreClient.OperationOptions {
|
||||
/** Delay to wait until next poll, in milliseconds. */
|
||||
updateIntervalInMs?: number;
|
||||
/** A serialized poller which can be used to resume an existing paused Long-Running-Operation. */
|
||||
resumeFrom?: string;
|
||||
}
|
||||
|
||||
/** Optional parameters. */
|
||||
export interface ContactProfilesUpdateTagsOptionalParams
|
||||
extends coreClient.OperationOptions {}
|
||||
|
||||
/** Contains response data for the updateTags operation. */
|
||||
export type ContactProfilesUpdateTagsResponse = ContactProfile;
|
||||
|
||||
/** Optional parameters. */
|
||||
export interface ContactProfilesListBySubscriptionOptionalParams
|
||||
extends coreClient.OperationOptions {}
|
||||
|
||||
/** Contains response data for the listBySubscription operation. */
|
||||
export type ContactProfilesListBySubscriptionResponse = ContactProfileListResult;
|
||||
|
||||
/** Optional parameters. */
|
||||
export interface ContactProfilesListOptionalParams
|
||||
extends coreClient.OperationOptions {}
|
||||
|
||||
/** Contains response data for the list operation. */
|
||||
export type ContactProfilesListResponse = ContactProfileListResult;
|
||||
|
||||
/** Optional parameters. */
|
||||
export interface AvailableGroundStationsListByCapabilityOptionalParams
|
||||
extends coreClient.OperationOptions {}
|
||||
|
||||
/** Contains response data for the listByCapability operation. */
|
||||
export type AvailableGroundStationsListByCapabilityResponse = AvailableGroundStationListResult;
|
||||
|
||||
/** Optional parameters. */
|
||||
export interface AvailableGroundStationsGetOptionalParams
|
||||
extends coreClient.OperationOptions {}
|
||||
|
||||
/** Contains response data for the get operation. */
|
||||
export type AvailableGroundStationsGetResponse = AvailableGroundStation;
|
||||
|
||||
/** Optional parameters. */
|
||||
export interface AvailableGroundStationsListByCapabilityNextOptionalParams
|
||||
extends coreClient.OperationOptions {}
|
||||
|
||||
/** Contains response data for the listByCapabilityNext operation. */
|
||||
export type AvailableGroundStationsListByCapabilityNextResponse = AvailableGroundStationListResult;
|
||||
|
||||
/** Optional parameters. */
|
||||
export interface AzureOrbitalOptionalParams
|
||||
extends coreClient.ServiceClientOptions {
|
||||
/** server parameter */
|
||||
$host?: string;
|
||||
/** Api Version */
|
||||
apiVersion?: string;
|
||||
/** Overrides client endpoint. */
|
||||
endpoint?: string;
|
||||
}
|
Разница между файлами не показана из-за своего большого размера
Загрузить разницу
|
@ -0,0 +1,260 @@
|
|||
/*
|
||||
* Copyright (c) Microsoft Corporation.
|
||||
* Licensed under the MIT License.
|
||||
*
|
||||
* Code generated by Microsoft (R) AutoRest Code Generator.
|
||||
* Changes may cause incorrect behavior and will be lost if the code is regenerated.
|
||||
*/
|
||||
|
||||
import {
|
||||
OperationParameter,
|
||||
OperationURLParameter,
|
||||
OperationQueryParameter
|
||||
} from "@azure/core-client";
|
||||
import {
|
||||
Spacecraft as SpacecraftMapper,
|
||||
TagsObject as TagsObjectMapper,
|
||||
ContactParameters as ContactParametersMapper,
|
||||
Contact as ContactMapper,
|
||||
ContactProfile as ContactProfileMapper
|
||||
} from "../models/mappers";
|
||||
|
||||
export const accept: OperationParameter = {
|
||||
parameterPath: "accept",
|
||||
mapper: {
|
||||
defaultValue: "application/json",
|
||||
isConstant: true,
|
||||
serializedName: "Accept",
|
||||
type: {
|
||||
name: "String"
|
||||
}
|
||||
}
|
||||
};
|
||||
|
||||
export const $host: OperationURLParameter = {
|
||||
parameterPath: "$host",
|
||||
mapper: {
|
||||
serializedName: "$host",
|
||||
required: true,
|
||||
type: {
|
||||
name: "String"
|
||||
}
|
||||
},
|
||||
skipEncoding: true
|
||||
};
|
||||
|
||||
export const apiVersion: OperationQueryParameter = {
|
||||
parameterPath: "apiVersion",
|
||||
mapper: {
|
||||
defaultValue: "2021-04-04-preview",
|
||||
isConstant: true,
|
||||
serializedName: "api-version",
|
||||
type: {
|
||||
name: "String"
|
||||
}
|
||||
}
|
||||
};
|
||||
|
||||
export const subscriptionId: OperationURLParameter = {
|
||||
parameterPath: "subscriptionId",
|
||||
mapper: {
|
||||
constraints: {
|
||||
MinLength: 1
|
||||
},
|
||||
serializedName: "subscriptionId",
|
||||
required: true,
|
||||
type: {
|
||||
name: "String"
|
||||
}
|
||||
}
|
||||
};
|
||||
|
||||
export const resourceGroupName: OperationURLParameter = {
|
||||
parameterPath: "resourceGroupName",
|
||||
mapper: {
|
||||
constraints: {
|
||||
MaxLength: 90,
|
||||
MinLength: 1
|
||||
},
|
||||
serializedName: "resourceGroupName",
|
||||
required: true,
|
||||
type: {
|
||||
name: "String"
|
||||
}
|
||||
}
|
||||
};
|
||||
|
||||
export const spacecraftName: OperationURLParameter = {
|
||||
parameterPath: "spacecraftName",
|
||||
mapper: {
|
||||
serializedName: "spacecraftName",
|
||||
required: true,
|
||||
type: {
|
||||
name: "String"
|
||||
}
|
||||
}
|
||||
};
|
||||
|
||||
export const contentType: OperationParameter = {
|
||||
parameterPath: ["options", "contentType"],
|
||||
mapper: {
|
||||
defaultValue: "application/json",
|
||||
isConstant: true,
|
||||
serializedName: "Content-Type",
|
||||
type: {
|
||||
name: "String"
|
||||
}
|
||||
}
|
||||
};
|
||||
|
||||
export const tags: OperationParameter = {
|
||||
parameterPath: ["options", "tags"],
|
||||
mapper: SpacecraftMapper
|
||||
};
|
||||
|
||||
export const location: OperationParameter = {
|
||||
parameterPath: "location",
|
||||
mapper: SpacecraftMapper
|
||||
};
|
||||
|
||||
export const noradId: OperationParameter = {
|
||||
parameterPath: ["options", "noradId"],
|
||||
mapper: SpacecraftMapper
|
||||
};
|
||||
|
||||
export const titleLine: OperationParameter = {
|
||||
parameterPath: ["options", "titleLine"],
|
||||
mapper: SpacecraftMapper
|
||||
};
|
||||
|
||||
export const tleLine1: OperationParameter = {
|
||||
parameterPath: ["options", "tleLine1"],
|
||||
mapper: SpacecraftMapper
|
||||
};
|
||||
|
||||
export const tleLine2: OperationParameter = {
|
||||
parameterPath: ["options", "tleLine2"],
|
||||
mapper: SpacecraftMapper
|
||||
};
|
||||
|
||||
export const links: OperationParameter = {
|
||||
parameterPath: ["options", "links"],
|
||||
mapper: SpacecraftMapper
|
||||
};
|
||||
|
||||
export const parameters1: OperationParameter = {
|
||||
parameterPath: "parameters",
|
||||
mapper: TagsObjectMapper
|
||||
};
|
||||
|
||||
export const contactProfile: OperationParameter = {
|
||||
parameterPath: "contactProfile",
|
||||
mapper: ContactParametersMapper
|
||||
};
|
||||
|
||||
export const groundStationName: OperationParameter = {
|
||||
parameterPath: "groundStationName",
|
||||
mapper: ContactParametersMapper
|
||||
};
|
||||
|
||||
export const startTime: OperationParameter = {
|
||||
parameterPath: "startTime",
|
||||
mapper: ContactParametersMapper
|
||||
};
|
||||
|
||||
export const endTime: OperationParameter = {
|
||||
parameterPath: "endTime",
|
||||
mapper: ContactParametersMapper
|
||||
};
|
||||
|
||||
export const contactName: OperationURLParameter = {
|
||||
parameterPath: "contactName",
|
||||
mapper: {
|
||||
serializedName: "contactName",
|
||||
required: true,
|
||||
type: {
|
||||
name: "String"
|
||||
}
|
||||
}
|
||||
};
|
||||
|
||||
export const parameters3: OperationParameter = {
|
||||
parameterPath: "parameters",
|
||||
mapper: ContactMapper
|
||||
};
|
||||
|
||||
export const contactProfileName: OperationURLParameter = {
|
||||
parameterPath: "contactProfileName",
|
||||
mapper: {
|
||||
serializedName: "contactProfileName",
|
||||
required: true,
|
||||
type: {
|
||||
name: "String"
|
||||
}
|
||||
}
|
||||
};
|
||||
|
||||
export const tags1: OperationParameter = {
|
||||
parameterPath: ["options", "tags"],
|
||||
mapper: ContactProfileMapper
|
||||
};
|
||||
|
||||
export const location1: OperationParameter = {
|
||||
parameterPath: "location",
|
||||
mapper: ContactProfileMapper
|
||||
};
|
||||
|
||||
export const minimumViableContactDuration: OperationParameter = {
|
||||
parameterPath: ["options", "minimumViableContactDuration"],
|
||||
mapper: ContactProfileMapper
|
||||
};
|
||||
|
||||
export const minimumElevationDegrees: OperationParameter = {
|
||||
parameterPath: ["options", "minimumElevationDegrees"],
|
||||
mapper: ContactProfileMapper
|
||||
};
|
||||
|
||||
export const autoTrackingConfiguration: OperationParameter = {
|
||||
parameterPath: ["options", "autoTrackingConfiguration"],
|
||||
mapper: ContactProfileMapper
|
||||
};
|
||||
|
||||
export const links1: OperationParameter = {
|
||||
parameterPath: ["options", "links"],
|
||||
mapper: ContactProfileMapper
|
||||
};
|
||||
|
||||
export const capability: OperationQueryParameter = {
|
||||
parameterPath: "capability",
|
||||
mapper: {
|
||||
defaultValue: "EarthObservation",
|
||||
serializedName: "capability",
|
||||
required: true,
|
||||
type: {
|
||||
name: "String"
|
||||
}
|
||||
}
|
||||
};
|
||||
|
||||
export const groundStationName1: OperationURLParameter = {
|
||||
parameterPath: "groundStationName",
|
||||
mapper: {
|
||||
serializedName: "groundStationName",
|
||||
required: true,
|
||||
type: {
|
||||
name: "String"
|
||||
}
|
||||
}
|
||||
};
|
||||
|
||||
export const nextLink: OperationURLParameter = {
|
||||
parameterPath: "nextLink",
|
||||
mapper: {
|
||||
serializedName: "nextLink",
|
||||
required: true,
|
||||
type: {
|
||||
name: "String"
|
||||
}
|
||||
},
|
||||
skipEncoding: true
|
||||
};
|
|
@ -0,0 +1,199 @@
|
|||
/*
|
||||
* Copyright (c) Microsoft Corporation.
|
||||
* Licensed under the MIT License.
|
||||
*
|
||||
* Code generated by Microsoft (R) AutoRest Code Generator.
|
||||
* Changes may cause incorrect behavior and will be lost if the code is regenerated.
|
||||
*/
|
||||
|
||||
import { PagedAsyncIterableIterator } from "@azure/core-paging";
|
||||
import { AvailableGroundStations } from "../operationsInterfaces";
|
||||
import * as coreClient from "@azure/core-client";
|
||||
import * as Mappers from "../models/mappers";
|
||||
import * as Parameters from "../models/parameters";
|
||||
import { AzureOrbitalContext } from "../azureOrbitalContext";
|
||||
import {
|
||||
AvailableGroundStation,
|
||||
Enum6,
|
||||
AvailableGroundStationsListByCapabilityNextOptionalParams,
|
||||
AvailableGroundStationsListByCapabilityOptionalParams,
|
||||
AvailableGroundStationsListByCapabilityResponse,
|
||||
AvailableGroundStationsGetOptionalParams,
|
||||
AvailableGroundStationsGetResponse,
|
||||
AvailableGroundStationsListByCapabilityNextResponse
|
||||
} from "../models";
|
||||
|
||||
/// <reference lib="esnext.asynciterable" />
|
||||
/** Class containing AvailableGroundStations operations. */
|
||||
export class AvailableGroundStationsImpl implements AvailableGroundStations {
|
||||
private readonly client: AzureOrbitalContext;
|
||||
|
||||
/**
|
||||
* Initialize a new instance of the class AvailableGroundStations class.
|
||||
* @param client Reference to the service client
|
||||
*/
|
||||
constructor(client: AzureOrbitalContext) {
|
||||
this.client = client;
|
||||
}
|
||||
|
||||
/**
|
||||
* Returns list of available ground stations
|
||||
* @param capability Ground Station Capability
|
||||
* @param options The options parameters.
|
||||
*/
|
||||
public listByCapability(
|
||||
capability: Enum6,
|
||||
options?: AvailableGroundStationsListByCapabilityOptionalParams
|
||||
): PagedAsyncIterableIterator<AvailableGroundStation> {
|
||||
const iter = this.listByCapabilityPagingAll(capability, options);
|
||||
return {
|
||||
next() {
|
||||
return iter.next();
|
||||
},
|
||||
[Symbol.asyncIterator]() {
|
||||
return this;
|
||||
},
|
||||
byPage: () => {
|
||||
return this.listByCapabilityPagingPage(capability, options);
|
||||
}
|
||||
};
|
||||
}
|
||||
|
||||
private async *listByCapabilityPagingPage(
|
||||
capability: Enum6,
|
||||
options?: AvailableGroundStationsListByCapabilityOptionalParams
|
||||
): AsyncIterableIterator<AvailableGroundStation[]> {
|
||||
let result = await this._listByCapability(capability, options);
|
||||
yield result.value || [];
|
||||
let continuationToken = result.nextLink;
|
||||
while (continuationToken) {
|
||||
result = await this._listByCapabilityNext(
|
||||
capability,
|
||||
continuationToken,
|
||||
options
|
||||
);
|
||||
continuationToken = result.nextLink;
|
||||
yield result.value || [];
|
||||
}
|
||||
}
|
||||
|
||||
private async *listByCapabilityPagingAll(
|
||||
capability: Enum6,
|
||||
options?: AvailableGroundStationsListByCapabilityOptionalParams
|
||||
): AsyncIterableIterator<AvailableGroundStation> {
|
||||
for await (const page of this.listByCapabilityPagingPage(
|
||||
capability,
|
||||
options
|
||||
)) {
|
||||
yield* page;
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Returns list of available ground stations
|
||||
* @param capability Ground Station Capability
|
||||
* @param options The options parameters.
|
||||
*/
|
||||
private _listByCapability(
|
||||
capability: Enum6,
|
||||
options?: AvailableGroundStationsListByCapabilityOptionalParams
|
||||
): Promise<AvailableGroundStationsListByCapabilityResponse> {
|
||||
return this.client.sendOperationRequest(
|
||||
{ capability, options },
|
||||
listByCapabilityOperationSpec
|
||||
);
|
||||
}
|
||||
|
||||
/**
|
||||
* Gets the specified available ground station
|
||||
* @param groundStationName Ground Station name
|
||||
* @param options The options parameters.
|
||||
*/
|
||||
get(
|
||||
groundStationName: string,
|
||||
options?: AvailableGroundStationsGetOptionalParams
|
||||
): Promise<AvailableGroundStationsGetResponse> {
|
||||
return this.client.sendOperationRequest(
|
||||
{ groundStationName, options },
|
||||
getOperationSpec
|
||||
);
|
||||
}
|
||||
|
||||
/**
|
||||
* ListByCapabilityNext
|
||||
* @param capability Ground Station Capability
|
||||
* @param nextLink The nextLink from the previous successful call to the ListByCapability method.
|
||||
* @param options The options parameters.
|
||||
*/
|
||||
private _listByCapabilityNext(
|
||||
capability: Enum6,
|
||||
nextLink: string,
|
||||
options?: AvailableGroundStationsListByCapabilityNextOptionalParams
|
||||
): Promise<AvailableGroundStationsListByCapabilityNextResponse> {
|
||||
return this.client.sendOperationRequest(
|
||||
{ capability, nextLink, options },
|
||||
listByCapabilityNextOperationSpec
|
||||
);
|
||||
}
|
||||
}
|
||||
// Operation Specifications
|
||||
const serializer = coreClient.createSerializer(Mappers, /* isXml */ false);
|
||||
|
||||
const listByCapabilityOperationSpec: coreClient.OperationSpec = {
|
||||
path:
|
||||
"/subscriptions/{subscriptionId}/providers/Microsoft.Orbital/availableGroundStations",
|
||||
httpMethod: "GET",
|
||||
responses: {
|
||||
200: {
|
||||
bodyMapper: Mappers.AvailableGroundStationListResult
|
||||
},
|
||||
default: {
|
||||
bodyMapper: Mappers.CloudError
|
||||
}
|
||||
},
|
||||
queryParameters: [Parameters.apiVersion, Parameters.capability],
|
||||
urlParameters: [Parameters.$host, Parameters.subscriptionId],
|
||||
headerParameters: [Parameters.accept],
|
||||
serializer
|
||||
};
|
||||
const getOperationSpec: coreClient.OperationSpec = {
|
||||
path:
|
||||
"/subscriptions/{subscriptionId}/providers/Microsoft.Orbital/availableGroundStations/{groundStationName}",
|
||||
httpMethod: "GET",
|
||||
responses: {
|
||||
200: {
|
||||
bodyMapper: Mappers.AvailableGroundStation
|
||||
},
|
||||
default: {
|
||||
bodyMapper: Mappers.CloudError
|
||||
}
|
||||
},
|
||||
queryParameters: [Parameters.apiVersion],
|
||||
urlParameters: [
|
||||
Parameters.$host,
|
||||
Parameters.subscriptionId,
|
||||
Parameters.groundStationName1
|
||||
],
|
||||
headerParameters: [Parameters.accept],
|
||||
serializer
|
||||
};
|
||||
const listByCapabilityNextOperationSpec: coreClient.OperationSpec = {
|
||||
path: "{nextLink}",
|
||||
httpMethod: "GET",
|
||||
responses: {
|
||||
200: {
|
||||
bodyMapper: Mappers.AvailableGroundStationListResult
|
||||
},
|
||||
default: {
|
||||
bodyMapper: Mappers.CloudError
|
||||
}
|
||||
},
|
||||
queryParameters: [Parameters.apiVersion, Parameters.capability],
|
||||
urlParameters: [
|
||||
Parameters.$host,
|
||||
Parameters.subscriptionId,
|
||||
Parameters.nextLink
|
||||
],
|
||||
headerParameters: [Parameters.accept],
|
||||
serializer
|
||||
};
|
|
@ -0,0 +1,510 @@
|
|||
/*
|
||||
* Copyright (c) Microsoft Corporation.
|
||||
* Licensed under the MIT License.
|
||||
*
|
||||
* Code generated by Microsoft (R) AutoRest Code Generator.
|
||||
* Changes may cause incorrect behavior and will be lost if the code is regenerated.
|
||||
*/
|
||||
|
||||
import { PagedAsyncIterableIterator } from "@azure/core-paging";
|
||||
import { ContactProfiles } from "../operationsInterfaces";
|
||||
import * as coreClient from "@azure/core-client";
|
||||
import * as Mappers from "../models/mappers";
|
||||
import * as Parameters from "../models/parameters";
|
||||
import { AzureOrbitalContext } from "../azureOrbitalContext";
|
||||
import { PollerLike, PollOperationState, LroEngine } from "@azure/core-lro";
|
||||
import { LroImpl } from "../lroImpl";
|
||||
import {
|
||||
ContactProfile,
|
||||
ContactProfilesListBySubscriptionOptionalParams,
|
||||
ContactProfilesListOptionalParams,
|
||||
ContactProfilesGetOptionalParams,
|
||||
ContactProfilesGetResponse,
|
||||
ContactProfilesCreateOrUpdateOptionalParams,
|
||||
ContactProfilesCreateOrUpdateResponse,
|
||||
ContactProfilesDeleteOptionalParams,
|
||||
TagsObject,
|
||||
ContactProfilesUpdateTagsOptionalParams,
|
||||
ContactProfilesUpdateTagsResponse,
|
||||
ContactProfilesListBySubscriptionResponse,
|
||||
ContactProfilesListResponse
|
||||
} from "../models";
|
||||
|
||||
/// <reference lib="esnext.asynciterable" />
|
||||
/** Class containing ContactProfiles operations. */
|
||||
export class ContactProfilesImpl implements ContactProfiles {
|
||||
private readonly client: AzureOrbitalContext;
|
||||
|
||||
/**
|
||||
* Initialize a new instance of the class ContactProfiles class.
|
||||
* @param client Reference to the service client
|
||||
*/
|
||||
constructor(client: AzureOrbitalContext) {
|
||||
this.client = client;
|
||||
}
|
||||
|
||||
/**
|
||||
* Returns list of contact profiles
|
||||
* @param options The options parameters.
|
||||
*/
|
||||
public listBySubscription(
|
||||
options?: ContactProfilesListBySubscriptionOptionalParams
|
||||
): PagedAsyncIterableIterator<ContactProfile> {
|
||||
const iter = this.listBySubscriptionPagingAll(options);
|
||||
return {
|
||||
next() {
|
||||
return iter.next();
|
||||
},
|
||||
[Symbol.asyncIterator]() {
|
||||
return this;
|
||||
},
|
||||
byPage: () => {
|
||||
return this.listBySubscriptionPagingPage(options);
|
||||
}
|
||||
};
|
||||
}
|
||||
|
||||
private async *listBySubscriptionPagingPage(
|
||||
options?: ContactProfilesListBySubscriptionOptionalParams
|
||||
): AsyncIterableIterator<ContactProfile[]> {
|
||||
let result = await this._listBySubscription(options);
|
||||
yield result.value || [];
|
||||
}
|
||||
|
||||
private async *listBySubscriptionPagingAll(
|
||||
options?: ContactProfilesListBySubscriptionOptionalParams
|
||||
): AsyncIterableIterator<ContactProfile> {
|
||||
for await (const page of this.listBySubscriptionPagingPage(options)) {
|
||||
yield* page;
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Returns list of contact profiles
|
||||
* @param resourceGroupName The name of the resource group. The name is case insensitive.
|
||||
* @param options The options parameters.
|
||||
*/
|
||||
public list(
|
||||
resourceGroupName: string,
|
||||
options?: ContactProfilesListOptionalParams
|
||||
): PagedAsyncIterableIterator<ContactProfile> {
|
||||
const iter = this.listPagingAll(resourceGroupName, options);
|
||||
return {
|
||||
next() {
|
||||
return iter.next();
|
||||
},
|
||||
[Symbol.asyncIterator]() {
|
||||
return this;
|
||||
},
|
||||
byPage: () => {
|
||||
return this.listPagingPage(resourceGroupName, options);
|
||||
}
|
||||
};
|
||||
}
|
||||
|
||||
private async *listPagingPage(
|
||||
resourceGroupName: string,
|
||||
options?: ContactProfilesListOptionalParams
|
||||
): AsyncIterableIterator<ContactProfile[]> {
|
||||
let result = await this._list(resourceGroupName, options);
|
||||
yield result.value || [];
|
||||
}
|
||||
|
||||
private async *listPagingAll(
|
||||
resourceGroupName: string,
|
||||
options?: ContactProfilesListOptionalParams
|
||||
): AsyncIterableIterator<ContactProfile> {
|
||||
for await (const page of this.listPagingPage(resourceGroupName, options)) {
|
||||
yield* page;
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Gets the specified contact Profile in a specified resource group
|
||||
* @param resourceGroupName The name of the resource group. The name is case insensitive.
|
||||
* @param contactProfileName Contact Profile Name
|
||||
* @param options The options parameters.
|
||||
*/
|
||||
get(
|
||||
resourceGroupName: string,
|
||||
contactProfileName: string,
|
||||
options?: ContactProfilesGetOptionalParams
|
||||
): Promise<ContactProfilesGetResponse> {
|
||||
return this.client.sendOperationRequest(
|
||||
{ resourceGroupName, contactProfileName, options },
|
||||
getOperationSpec
|
||||
);
|
||||
}
|
||||
|
||||
/**
|
||||
* Creates or updates a contact profile
|
||||
* @param resourceGroupName The name of the resource group. The name is case insensitive.
|
||||
* @param contactProfileName Contact Profile Name
|
||||
* @param location The geo-location where the resource lives
|
||||
* @param options The options parameters.
|
||||
*/
|
||||
async beginCreateOrUpdate(
|
||||
resourceGroupName: string,
|
||||
contactProfileName: string,
|
||||
location: string,
|
||||
options?: ContactProfilesCreateOrUpdateOptionalParams
|
||||
): Promise<
|
||||
PollerLike<
|
||||
PollOperationState<ContactProfilesCreateOrUpdateResponse>,
|
||||
ContactProfilesCreateOrUpdateResponse
|
||||
>
|
||||
> {
|
||||
const directSendOperation = async (
|
||||
args: coreClient.OperationArguments,
|
||||
spec: coreClient.OperationSpec
|
||||
): Promise<ContactProfilesCreateOrUpdateResponse> => {
|
||||
return this.client.sendOperationRequest(args, spec);
|
||||
};
|
||||
const sendOperation = async (
|
||||
args: coreClient.OperationArguments,
|
||||
spec: coreClient.OperationSpec
|
||||
) => {
|
||||
let currentRawResponse:
|
||||
| coreClient.FullOperationResponse
|
||||
| undefined = undefined;
|
||||
const providedCallback = args.options?.onResponse;
|
||||
const callback: coreClient.RawResponseCallback = (
|
||||
rawResponse: coreClient.FullOperationResponse,
|
||||
flatResponse: unknown
|
||||
) => {
|
||||
currentRawResponse = rawResponse;
|
||||
providedCallback?.(rawResponse, flatResponse);
|
||||
};
|
||||
const updatedArgs = {
|
||||
...args,
|
||||
options: {
|
||||
...args.options,
|
||||
onResponse: callback
|
||||
}
|
||||
};
|
||||
const flatResponse = await directSendOperation(updatedArgs, spec);
|
||||
return {
|
||||
flatResponse,
|
||||
rawResponse: {
|
||||
statusCode: currentRawResponse!.status,
|
||||
body: currentRawResponse!.parsedBody,
|
||||
headers: currentRawResponse!.headers.toJSON()
|
||||
}
|
||||
};
|
||||
};
|
||||
|
||||
const lro = new LroImpl(
|
||||
sendOperation,
|
||||
{ resourceGroupName, contactProfileName, location, options },
|
||||
createOrUpdateOperationSpec
|
||||
);
|
||||
return new LroEngine(lro, {
|
||||
resumeFrom: options?.resumeFrom,
|
||||
intervalInMs: options?.updateIntervalInMs,
|
||||
lroResourceLocationConfig: "azure-async-operation"
|
||||
});
|
||||
}
|
||||
|
||||
/**
|
||||
* Creates or updates a contact profile
|
||||
* @param resourceGroupName The name of the resource group. The name is case insensitive.
|
||||
* @param contactProfileName Contact Profile Name
|
||||
* @param location The geo-location where the resource lives
|
||||
* @param options The options parameters.
|
||||
*/
|
||||
async beginCreateOrUpdateAndWait(
|
||||
resourceGroupName: string,
|
||||
contactProfileName: string,
|
||||
location: string,
|
||||
options?: ContactProfilesCreateOrUpdateOptionalParams
|
||||
): Promise<ContactProfilesCreateOrUpdateResponse> {
|
||||
const poller = await this.beginCreateOrUpdate(
|
||||
resourceGroupName,
|
||||
contactProfileName,
|
||||
location,
|
||||
options
|
||||
);
|
||||
return poller.pollUntilDone();
|
||||
}
|
||||
|
||||
/**
|
||||
* Deletes a specified contact profile resource.
|
||||
* @param resourceGroupName The name of the resource group. The name is case insensitive.
|
||||
* @param contactProfileName Contact Profile Name
|
||||
* @param options The options parameters.
|
||||
*/
|
||||
async beginDelete(
|
||||
resourceGroupName: string,
|
||||
contactProfileName: string,
|
||||
options?: ContactProfilesDeleteOptionalParams
|
||||
): Promise<PollerLike<PollOperationState<void>, void>> {
|
||||
const directSendOperation = async (
|
||||
args: coreClient.OperationArguments,
|
||||
spec: coreClient.OperationSpec
|
||||
): Promise<void> => {
|
||||
return this.client.sendOperationRequest(args, spec);
|
||||
};
|
||||
const sendOperation = async (
|
||||
args: coreClient.OperationArguments,
|
||||
spec: coreClient.OperationSpec
|
||||
) => {
|
||||
let currentRawResponse:
|
||||
| coreClient.FullOperationResponse
|
||||
| undefined = undefined;
|
||||
const providedCallback = args.options?.onResponse;
|
||||
const callback: coreClient.RawResponseCallback = (
|
||||
rawResponse: coreClient.FullOperationResponse,
|
||||
flatResponse: unknown
|
||||
) => {
|
||||
currentRawResponse = rawResponse;
|
||||
providedCallback?.(rawResponse, flatResponse);
|
||||
};
|
||||
const updatedArgs = {
|
||||
...args,
|
||||
options: {
|
||||
...args.options,
|
||||
onResponse: callback
|
||||
}
|
||||
};
|
||||
const flatResponse = await directSendOperation(updatedArgs, spec);
|
||||
return {
|
||||
flatResponse,
|
||||
rawResponse: {
|
||||
statusCode: currentRawResponse!.status,
|
||||
body: currentRawResponse!.parsedBody,
|
||||
headers: currentRawResponse!.headers.toJSON()
|
||||
}
|
||||
};
|
||||
};
|
||||
|
||||
const lro = new LroImpl(
|
||||
sendOperation,
|
||||
{ resourceGroupName, contactProfileName, options },
|
||||
deleteOperationSpec
|
||||
);
|
||||
return new LroEngine(lro, {
|
||||
resumeFrom: options?.resumeFrom,
|
||||
intervalInMs: options?.updateIntervalInMs,
|
||||
lroResourceLocationConfig: "location"
|
||||
});
|
||||
}
|
||||
|
||||
/**
|
||||
* Deletes a specified contact profile resource.
|
||||
* @param resourceGroupName The name of the resource group. The name is case insensitive.
|
||||
* @param contactProfileName Contact Profile Name
|
||||
* @param options The options parameters.
|
||||
*/
|
||||
async beginDeleteAndWait(
|
||||
resourceGroupName: string,
|
||||
contactProfileName: string,
|
||||
options?: ContactProfilesDeleteOptionalParams
|
||||
): Promise<void> {
|
||||
const poller = await this.beginDelete(
|
||||
resourceGroupName,
|
||||
contactProfileName,
|
||||
options
|
||||
);
|
||||
return poller.pollUntilDone();
|
||||
}
|
||||
|
||||
/**
|
||||
* Updates the specified contact profile tags.
|
||||
* @param resourceGroupName The name of the resource group. The name is case insensitive.
|
||||
* @param contactProfileName Contact Profile Name
|
||||
* @param parameters Parameters supplied to update contact profile tags.
|
||||
* @param options The options parameters.
|
||||
*/
|
||||
updateTags(
|
||||
resourceGroupName: string,
|
||||
contactProfileName: string,
|
||||
parameters: TagsObject,
|
||||
options?: ContactProfilesUpdateTagsOptionalParams
|
||||
): Promise<ContactProfilesUpdateTagsResponse> {
|
||||
return this.client.sendOperationRequest(
|
||||
{ resourceGroupName, contactProfileName, parameters, options },
|
||||
updateTagsOperationSpec
|
||||
);
|
||||
}
|
||||
|
||||
/**
|
||||
* Returns list of contact profiles
|
||||
* @param options The options parameters.
|
||||
*/
|
||||
private _listBySubscription(
|
||||
options?: ContactProfilesListBySubscriptionOptionalParams
|
||||
): Promise<ContactProfilesListBySubscriptionResponse> {
|
||||
return this.client.sendOperationRequest(
|
||||
{ options },
|
||||
listBySubscriptionOperationSpec
|
||||
);
|
||||
}
|
||||
|
||||
/**
|
||||
* Returns list of contact profiles
|
||||
* @param resourceGroupName The name of the resource group. The name is case insensitive.
|
||||
* @param options The options parameters.
|
||||
*/
|
||||
private _list(
|
||||
resourceGroupName: string,
|
||||
options?: ContactProfilesListOptionalParams
|
||||
): Promise<ContactProfilesListResponse> {
|
||||
return this.client.sendOperationRequest(
|
||||
{ resourceGroupName, options },
|
||||
listOperationSpec
|
||||
);
|
||||
}
|
||||
}
|
||||
// Operation Specifications
|
||||
const serializer = coreClient.createSerializer(Mappers, /* isXml */ false);
|
||||
|
||||
const getOperationSpec: coreClient.OperationSpec = {
|
||||
path:
|
||||
"/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Orbital/contactProfiles/{contactProfileName}",
|
||||
httpMethod: "GET",
|
||||
responses: {
|
||||
200: {
|
||||
bodyMapper: Mappers.ContactProfile
|
||||
},
|
||||
default: {
|
||||
bodyMapper: Mappers.CloudError
|
||||
}
|
||||
},
|
||||
queryParameters: [Parameters.apiVersion],
|
||||
urlParameters: [
|
||||
Parameters.$host,
|
||||
Parameters.subscriptionId,
|
||||
Parameters.resourceGroupName,
|
||||
Parameters.contactProfileName
|
||||
],
|
||||
headerParameters: [Parameters.accept],
|
||||
serializer
|
||||
};
|
||||
const createOrUpdateOperationSpec: coreClient.OperationSpec = {
|
||||
path:
|
||||
"/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Orbital/contactProfiles/{contactProfileName}",
|
||||
httpMethod: "PUT",
|
||||
responses: {
|
||||
200: {
|
||||
bodyMapper: Mappers.ContactProfile
|
||||
},
|
||||
201: {
|
||||
bodyMapper: Mappers.ContactProfile
|
||||
},
|
||||
202: {
|
||||
bodyMapper: Mappers.ContactProfile
|
||||
},
|
||||
204: {
|
||||
bodyMapper: Mappers.ContactProfile
|
||||
},
|
||||
default: {
|
||||
bodyMapper: Mappers.CloudError
|
||||
}
|
||||
},
|
||||
requestBody: {
|
||||
parameterPath: {
|
||||
tags: ["options", "tags"],
|
||||
location: ["location"],
|
||||
minimumViableContactDuration: ["options", "minimumViableContactDuration"],
|
||||
minimumElevationDegrees: ["options", "minimumElevationDegrees"],
|
||||
autoTrackingConfiguration: ["options", "autoTrackingConfiguration"],
|
||||
links: ["options", "links"]
|
||||
},
|
||||
mapper: { ...Mappers.ContactProfile, required: true }
|
||||
},
|
||||
queryParameters: [Parameters.apiVersion],
|
||||
urlParameters: [
|
||||
Parameters.$host,
|
||||
Parameters.subscriptionId,
|
||||
Parameters.resourceGroupName,
|
||||
Parameters.contactProfileName
|
||||
],
|
||||
headerParameters: [Parameters.accept, Parameters.contentType],
|
||||
mediaType: "json",
|
||||
serializer
|
||||
};
|
||||
const deleteOperationSpec: coreClient.OperationSpec = {
|
||||
path:
|
||||
"/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Orbital/contactProfiles/{contactProfileName}",
|
||||
httpMethod: "DELETE",
|
||||
responses: {
|
||||
200: {},
|
||||
201: {},
|
||||
202: {},
|
||||
204: {},
|
||||
default: {
|
||||
bodyMapper: Mappers.CloudError
|
||||
}
|
||||
},
|
||||
queryParameters: [Parameters.apiVersion],
|
||||
urlParameters: [
|
||||
Parameters.$host,
|
||||
Parameters.subscriptionId,
|
||||
Parameters.resourceGroupName,
|
||||
Parameters.contactProfileName
|
||||
],
|
||||
headerParameters: [Parameters.accept],
|
||||
serializer
|
||||
};
|
||||
const updateTagsOperationSpec: coreClient.OperationSpec = {
|
||||
path:
|
||||
"/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Orbital/contactProfiles/{contactProfileName}",
|
||||
httpMethod: "PATCH",
|
||||
responses: {
|
||||
200: {
|
||||
bodyMapper: Mappers.ContactProfile
|
||||
},
|
||||
default: {
|
||||
bodyMapper: Mappers.CloudError
|
||||
}
|
||||
},
|
||||
requestBody: Parameters.parameters1,
|
||||
queryParameters: [Parameters.apiVersion],
|
||||
urlParameters: [
|
||||
Parameters.$host,
|
||||
Parameters.subscriptionId,
|
||||
Parameters.resourceGroupName,
|
||||
Parameters.contactProfileName
|
||||
],
|
||||
headerParameters: [Parameters.accept, Parameters.contentType],
|
||||
mediaType: "json",
|
||||
serializer
|
||||
};
|
||||
const listBySubscriptionOperationSpec: coreClient.OperationSpec = {
|
||||
path:
|
||||
"/subscriptions/{subscriptionId}/providers/Microsoft.Orbital/contactProfiles",
|
||||
httpMethod: "GET",
|
||||
responses: {
|
||||
200: {
|
||||
bodyMapper: Mappers.ContactProfileListResult
|
||||
},
|
||||
default: {
|
||||
bodyMapper: Mappers.CloudError
|
||||
}
|
||||
},
|
||||
queryParameters: [Parameters.apiVersion],
|
||||
urlParameters: [Parameters.$host, Parameters.subscriptionId],
|
||||
headerParameters: [Parameters.accept],
|
||||
serializer
|
||||
};
|
||||
const listOperationSpec: coreClient.OperationSpec = {
|
||||
path:
|
||||
"/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Orbital/contactProfiles",
|
||||
httpMethod: "GET",
|
||||
responses: {
|
||||
200: {
|
||||
bodyMapper: Mappers.ContactProfileListResult
|
||||
},
|
||||
default: {
|
||||
bodyMapper: Mappers.CloudError
|
||||
}
|
||||
},
|
||||
queryParameters: [Parameters.apiVersion],
|
||||
urlParameters: [
|
||||
Parameters.$host,
|
||||
Parameters.subscriptionId,
|
||||
Parameters.resourceGroupName
|
||||
],
|
||||
headerParameters: [Parameters.accept],
|
||||
serializer
|
||||
};
|
|
@ -0,0 +1,412 @@
|
|||
/*
|
||||
* Copyright (c) Microsoft Corporation.
|
||||
* Licensed under the MIT License.
|
||||
*
|
||||
* Code generated by Microsoft (R) AutoRest Code Generator.
|
||||
* Changes may cause incorrect behavior and will be lost if the code is regenerated.
|
||||
*/
|
||||
|
||||
import { PagedAsyncIterableIterator } from "@azure/core-paging";
|
||||
import { Contacts } from "../operationsInterfaces";
|
||||
import * as coreClient from "@azure/core-client";
|
||||
import * as Mappers from "../models/mappers";
|
||||
import * as Parameters from "../models/parameters";
|
||||
import { AzureOrbitalContext } from "../azureOrbitalContext";
|
||||
import { PollerLike, PollOperationState, LroEngine } from "@azure/core-lro";
|
||||
import { LroImpl } from "../lroImpl";
|
||||
import {
|
||||
Contact,
|
||||
ContactsListOptionalParams,
|
||||
ContactsListResponse,
|
||||
ContactsGetOptionalParams,
|
||||
ContactsGetResponse,
|
||||
ContactsCreateOptionalParams,
|
||||
ContactsCreateResponse,
|
||||
ContactsDeleteOptionalParams
|
||||
} from "../models";
|
||||
|
||||
/// <reference lib="esnext.asynciterable" />
|
||||
/** Class containing Contacts operations. */
|
||||
export class ContactsImpl implements Contacts {
|
||||
private readonly client: AzureOrbitalContext;
|
||||
|
||||
/**
|
||||
* Initialize a new instance of the class Contacts class.
|
||||
* @param client Reference to the service client
|
||||
*/
|
||||
constructor(client: AzureOrbitalContext) {
|
||||
this.client = client;
|
||||
}
|
||||
|
||||
/**
|
||||
* Returns list of contacts by spacecraftName
|
||||
* @param resourceGroupName The name of the resource group. The name is case insensitive.
|
||||
* @param spacecraftName Spacecraft ID
|
||||
* @param options The options parameters.
|
||||
*/
|
||||
public list(
|
||||
resourceGroupName: string,
|
||||
spacecraftName: string,
|
||||
options?: ContactsListOptionalParams
|
||||
): PagedAsyncIterableIterator<Contact> {
|
||||
const iter = this.listPagingAll(resourceGroupName, spacecraftName, options);
|
||||
return {
|
||||
next() {
|
||||
return iter.next();
|
||||
},
|
||||
[Symbol.asyncIterator]() {
|
||||
return this;
|
||||
},
|
||||
byPage: () => {
|
||||
return this.listPagingPage(resourceGroupName, spacecraftName, options);
|
||||
}
|
||||
};
|
||||
}
|
||||
|
||||
private async *listPagingPage(
|
||||
resourceGroupName: string,
|
||||
spacecraftName: string,
|
||||
options?: ContactsListOptionalParams
|
||||
): AsyncIterableIterator<Contact[]> {
|
||||
let result = await this._list(resourceGroupName, spacecraftName, options);
|
||||
yield result.value || [];
|
||||
}
|
||||
|
||||
private async *listPagingAll(
|
||||
resourceGroupName: string,
|
||||
spacecraftName: string,
|
||||
options?: ContactsListOptionalParams
|
||||
): AsyncIterableIterator<Contact> {
|
||||
for await (const page of this.listPagingPage(
|
||||
resourceGroupName,
|
||||
spacecraftName,
|
||||
options
|
||||
)) {
|
||||
yield* page;
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Returns list of contacts by spacecraftName
|
||||
* @param resourceGroupName The name of the resource group. The name is case insensitive.
|
||||
* @param spacecraftName Spacecraft ID
|
||||
* @param options The options parameters.
|
||||
*/
|
||||
private _list(
|
||||
resourceGroupName: string,
|
||||
spacecraftName: string,
|
||||
options?: ContactsListOptionalParams
|
||||
): Promise<ContactsListResponse> {
|
||||
return this.client.sendOperationRequest(
|
||||
{ resourceGroupName, spacecraftName, options },
|
||||
listOperationSpec
|
||||
);
|
||||
}
|
||||
|
||||
/**
|
||||
* Gets the specified contact in a specified resource group
|
||||
* @param resourceGroupName The name of the resource group. The name is case insensitive.
|
||||
* @param spacecraftName Spacecraft ID
|
||||
* @param contactName Contact Name
|
||||
* @param options The options parameters.
|
||||
*/
|
||||
get(
|
||||
resourceGroupName: string,
|
||||
spacecraftName: string,
|
||||
contactName: string,
|
||||
options?: ContactsGetOptionalParams
|
||||
): Promise<ContactsGetResponse> {
|
||||
return this.client.sendOperationRequest(
|
||||
{ resourceGroupName, spacecraftName, contactName, options },
|
||||
getOperationSpec
|
||||
);
|
||||
}
|
||||
|
||||
/**
|
||||
* Creates a contact.
|
||||
* @param resourceGroupName The name of the resource group. The name is case insensitive.
|
||||
* @param spacecraftName Spacecraft ID
|
||||
* @param contactName Contact Name
|
||||
* @param parameters The parameters to provide for the created contact.
|
||||
* @param options The options parameters.
|
||||
*/
|
||||
async beginCreate(
|
||||
resourceGroupName: string,
|
||||
spacecraftName: string,
|
||||
contactName: string,
|
||||
parameters: Contact,
|
||||
options?: ContactsCreateOptionalParams
|
||||
): Promise<
|
||||
PollerLike<
|
||||
PollOperationState<ContactsCreateResponse>,
|
||||
ContactsCreateResponse
|
||||
>
|
||||
> {
|
||||
const directSendOperation = async (
|
||||
args: coreClient.OperationArguments,
|
||||
spec: coreClient.OperationSpec
|
||||
): Promise<ContactsCreateResponse> => {
|
||||
return this.client.sendOperationRequest(args, spec);
|
||||
};
|
||||
const sendOperation = async (
|
||||
args: coreClient.OperationArguments,
|
||||
spec: coreClient.OperationSpec
|
||||
) => {
|
||||
let currentRawResponse:
|
||||
| coreClient.FullOperationResponse
|
||||
| undefined = undefined;
|
||||
const providedCallback = args.options?.onResponse;
|
||||
const callback: coreClient.RawResponseCallback = (
|
||||
rawResponse: coreClient.FullOperationResponse,
|
||||
flatResponse: unknown
|
||||
) => {
|
||||
currentRawResponse = rawResponse;
|
||||
providedCallback?.(rawResponse, flatResponse);
|
||||
};
|
||||
const updatedArgs = {
|
||||
...args,
|
||||
options: {
|
||||
...args.options,
|
||||
onResponse: callback
|
||||
}
|
||||
};
|
||||
const flatResponse = await directSendOperation(updatedArgs, spec);
|
||||
return {
|
||||
flatResponse,
|
||||
rawResponse: {
|
||||
statusCode: currentRawResponse!.status,
|
||||
body: currentRawResponse!.parsedBody,
|
||||
headers: currentRawResponse!.headers.toJSON()
|
||||
}
|
||||
};
|
||||
};
|
||||
|
||||
const lro = new LroImpl(
|
||||
sendOperation,
|
||||
{ resourceGroupName, spacecraftName, contactName, parameters, options },
|
||||
createOperationSpec
|
||||
);
|
||||
return new LroEngine(lro, {
|
||||
resumeFrom: options?.resumeFrom,
|
||||
intervalInMs: options?.updateIntervalInMs,
|
||||
lroResourceLocationConfig: "azure-async-operation"
|
||||
});
|
||||
}
|
||||
|
||||
/**
|
||||
* Creates a contact.
|
||||
* @param resourceGroupName The name of the resource group. The name is case insensitive.
|
||||
* @param spacecraftName Spacecraft ID
|
||||
* @param contactName Contact Name
|
||||
* @param parameters The parameters to provide for the created contact.
|
||||
* @param options The options parameters.
|
||||
*/
|
||||
async beginCreateAndWait(
|
||||
resourceGroupName: string,
|
||||
spacecraftName: string,
|
||||
contactName: string,
|
||||
parameters: Contact,
|
||||
options?: ContactsCreateOptionalParams
|
||||
): Promise<ContactsCreateResponse> {
|
||||
const poller = await this.beginCreate(
|
||||
resourceGroupName,
|
||||
spacecraftName,
|
||||
contactName,
|
||||
parameters,
|
||||
options
|
||||
);
|
||||
return poller.pollUntilDone();
|
||||
}
|
||||
|
||||
/**
|
||||
* Deletes a specified contact
|
||||
* @param resourceGroupName The name of the resource group. The name is case insensitive.
|
||||
* @param spacecraftName Spacecraft ID
|
||||
* @param contactName Contact Name
|
||||
* @param options The options parameters.
|
||||
*/
|
||||
async beginDelete(
|
||||
resourceGroupName: string,
|
||||
spacecraftName: string,
|
||||
contactName: string,
|
||||
options?: ContactsDeleteOptionalParams
|
||||
): Promise<PollerLike<PollOperationState<void>, void>> {
|
||||
const directSendOperation = async (
|
||||
args: coreClient.OperationArguments,
|
||||
spec: coreClient.OperationSpec
|
||||
): Promise<void> => {
|
||||
return this.client.sendOperationRequest(args, spec);
|
||||
};
|
||||
const sendOperation = async (
|
||||
args: coreClient.OperationArguments,
|
||||
spec: coreClient.OperationSpec
|
||||
) => {
|
||||
let currentRawResponse:
|
||||
| coreClient.FullOperationResponse
|
||||
| undefined = undefined;
|
||||
const providedCallback = args.options?.onResponse;
|
||||
const callback: coreClient.RawResponseCallback = (
|
||||
rawResponse: coreClient.FullOperationResponse,
|
||||
flatResponse: unknown
|
||||
) => {
|
||||
currentRawResponse = rawResponse;
|
||||
providedCallback?.(rawResponse, flatResponse);
|
||||
};
|
||||
const updatedArgs = {
|
||||
...args,
|
||||
options: {
|
||||
...args.options,
|
||||
onResponse: callback
|
||||
}
|
||||
};
|
||||
const flatResponse = await directSendOperation(updatedArgs, spec);
|
||||
return {
|
||||
flatResponse,
|
||||
rawResponse: {
|
||||
statusCode: currentRawResponse!.status,
|
||||
body: currentRawResponse!.parsedBody,
|
||||
headers: currentRawResponse!.headers.toJSON()
|
||||
}
|
||||
};
|
||||
};
|
||||
|
||||
const lro = new LroImpl(
|
||||
sendOperation,
|
||||
{ resourceGroupName, spacecraftName, contactName, options },
|
||||
deleteOperationSpec
|
||||
);
|
||||
return new LroEngine(lro, {
|
||||
resumeFrom: options?.resumeFrom,
|
||||
intervalInMs: options?.updateIntervalInMs,
|
||||
lroResourceLocationConfig: "location"
|
||||
});
|
||||
}
|
||||
|
||||
/**
|
||||
* Deletes a specified contact
|
||||
* @param resourceGroupName The name of the resource group. The name is case insensitive.
|
||||
* @param spacecraftName Spacecraft ID
|
||||
* @param contactName Contact Name
|
||||
* @param options The options parameters.
|
||||
*/
|
||||
async beginDeleteAndWait(
|
||||
resourceGroupName: string,
|
||||
spacecraftName: string,
|
||||
contactName: string,
|
||||
options?: ContactsDeleteOptionalParams
|
||||
): Promise<void> {
|
||||
const poller = await this.beginDelete(
|
||||
resourceGroupName,
|
||||
spacecraftName,
|
||||
contactName,
|
||||
options
|
||||
);
|
||||
return poller.pollUntilDone();
|
||||
}
|
||||
}
|
||||
// Operation Specifications
|
||||
const serializer = coreClient.createSerializer(Mappers, /* isXml */ false);
|
||||
|
||||
const listOperationSpec: coreClient.OperationSpec = {
|
||||
path:
|
||||
"/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Orbital/spacecrafts/{spacecraftName}/contacts",
|
||||
httpMethod: "GET",
|
||||
responses: {
|
||||
200: {
|
||||
bodyMapper: Mappers.ContactListResult
|
||||
},
|
||||
default: {
|
||||
bodyMapper: Mappers.CloudError
|
||||
}
|
||||
},
|
||||
queryParameters: [Parameters.apiVersion],
|
||||
urlParameters: [
|
||||
Parameters.$host,
|
||||
Parameters.subscriptionId,
|
||||
Parameters.resourceGroupName,
|
||||
Parameters.spacecraftName
|
||||
],
|
||||
headerParameters: [Parameters.accept],
|
||||
serializer
|
||||
};
|
||||
const getOperationSpec: coreClient.OperationSpec = {
|
||||
path:
|
||||
"/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Orbital/spacecrafts/{spacecraftName}/contacts/{contactName}",
|
||||
httpMethod: "GET",
|
||||
responses: {
|
||||
200: {
|
||||
bodyMapper: Mappers.Contact
|
||||
},
|
||||
default: {
|
||||
bodyMapper: Mappers.CloudError
|
||||
}
|
||||
},
|
||||
queryParameters: [Parameters.apiVersion],
|
||||
urlParameters: [
|
||||
Parameters.$host,
|
||||
Parameters.subscriptionId,
|
||||
Parameters.resourceGroupName,
|
||||
Parameters.spacecraftName,
|
||||
Parameters.contactName
|
||||
],
|
||||
headerParameters: [Parameters.accept],
|
||||
serializer
|
||||
};
|
||||
const createOperationSpec: coreClient.OperationSpec = {
|
||||
path:
|
||||
"/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Orbital/spacecrafts/{spacecraftName}/contacts/{contactName}",
|
||||
httpMethod: "PUT",
|
||||
responses: {
|
||||
200: {
|
||||
bodyMapper: Mappers.Contact
|
||||
},
|
||||
201: {
|
||||
bodyMapper: Mappers.Contact
|
||||
},
|
||||
202: {
|
||||
bodyMapper: Mappers.Contact
|
||||
},
|
||||
204: {
|
||||
bodyMapper: Mappers.Contact
|
||||
},
|
||||
default: {
|
||||
bodyMapper: Mappers.CloudError
|
||||
}
|
||||
},
|
||||
requestBody: Parameters.parameters3,
|
||||
queryParameters: [Parameters.apiVersion],
|
||||
urlParameters: [
|
||||
Parameters.$host,
|
||||
Parameters.subscriptionId,
|
||||
Parameters.resourceGroupName,
|
||||
Parameters.spacecraftName,
|
||||
Parameters.contactName
|
||||
],
|
||||
headerParameters: [Parameters.accept, Parameters.contentType],
|
||||
mediaType: "json",
|
||||
serializer
|
||||
};
|
||||
const deleteOperationSpec: coreClient.OperationSpec = {
|
||||
path:
|
||||
"/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Orbital/spacecrafts/{spacecraftName}/contacts/{contactName}",
|
||||
httpMethod: "DELETE",
|
||||
responses: {
|
||||
200: {},
|
||||
201: {},
|
||||
202: {},
|
||||
204: {},
|
||||
default: {
|
||||
bodyMapper: Mappers.CloudError
|
||||
}
|
||||
},
|
||||
queryParameters: [Parameters.apiVersion],
|
||||
urlParameters: [
|
||||
Parameters.$host,
|
||||
Parameters.subscriptionId,
|
||||
Parameters.resourceGroupName,
|
||||
Parameters.spacecraftName,
|
||||
Parameters.contactName
|
||||
],
|
||||
headerParameters: [Parameters.accept],
|
||||
serializer
|
||||
};
|
|
@ -0,0 +1,13 @@
|
|||
/*
|
||||
* Copyright (c) Microsoft Corporation.
|
||||
* Licensed under the MIT License.
|
||||
*
|
||||
* Code generated by Microsoft (R) AutoRest Code Generator.
|
||||
* Changes may cause incorrect behavior and will be lost if the code is regenerated.
|
||||
*/
|
||||
|
||||
export * from "./operations";
|
||||
export * from "./spacecrafts";
|
||||
export * from "./contacts";
|
||||
export * from "./contactProfiles";
|
||||
export * from "./availableGroundStations";
|
|
@ -0,0 +1,98 @@
|
|||
/*
|
||||
* Copyright (c) Microsoft Corporation.
|
||||
* Licensed under the MIT License.
|
||||
*
|
||||
* Code generated by Microsoft (R) AutoRest Code Generator.
|
||||
* Changes may cause incorrect behavior and will be lost if the code is regenerated.
|
||||
*/
|
||||
|
||||
import { PagedAsyncIterableIterator } from "@azure/core-paging";
|
||||
import { Operations } from "../operationsInterfaces";
|
||||
import * as coreClient from "@azure/core-client";
|
||||
import * as Mappers from "../models/mappers";
|
||||
import * as Parameters from "../models/parameters";
|
||||
import { AzureOrbitalContext } from "../azureOrbitalContext";
|
||||
import {
|
||||
Operation,
|
||||
OperationsListOptionalParams,
|
||||
OperationsListResponse
|
||||
} from "../models";
|
||||
|
||||
/// <reference lib="esnext.asynciterable" />
|
||||
/** Class containing Operations operations. */
|
||||
export class OperationsImpl implements Operations {
|
||||
private readonly client: AzureOrbitalContext;
|
||||
|
||||
/**
|
||||
* Initialize a new instance of the class Operations class.
|
||||
* @param client Reference to the service client
|
||||
*/
|
||||
constructor(client: AzureOrbitalContext) {
|
||||
this.client = client;
|
||||
}
|
||||
|
||||
/**
|
||||
* Lists all of the available Orbital Rest API operations.
|
||||
* @param options The options parameters.
|
||||
*/
|
||||
public list(
|
||||
options?: OperationsListOptionalParams
|
||||
): PagedAsyncIterableIterator<Operation> {
|
||||
const iter = this.listPagingAll(options);
|
||||
return {
|
||||
next() {
|
||||
return iter.next();
|
||||
},
|
||||
[Symbol.asyncIterator]() {
|
||||
return this;
|
||||
},
|
||||
byPage: () => {
|
||||
return this.listPagingPage(options);
|
||||
}
|
||||
};
|
||||
}
|
||||
|
||||
private async *listPagingPage(
|
||||
options?: OperationsListOptionalParams
|
||||
): AsyncIterableIterator<Operation[]> {
|
||||
let result = await this._list(options);
|
||||
yield result.value || [];
|
||||
}
|
||||
|
||||
private async *listPagingAll(
|
||||
options?: OperationsListOptionalParams
|
||||
): AsyncIterableIterator<Operation> {
|
||||
for await (const page of this.listPagingPage(options)) {
|
||||
yield* page;
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Lists all of the available Orbital Rest API operations.
|
||||
* @param options The options parameters.
|
||||
*/
|
||||
private _list(
|
||||
options?: OperationsListOptionalParams
|
||||
): Promise<OperationsListResponse> {
|
||||
return this.client.sendOperationRequest({ options }, listOperationSpec);
|
||||
}
|
||||
}
|
||||
// Operation Specifications
|
||||
const serializer = coreClient.createSerializer(Mappers, /* isXml */ false);
|
||||
|
||||
const listOperationSpec: coreClient.OperationSpec = {
|
||||
path: "/providers/Microsoft.Orbital/operations",
|
||||
httpMethod: "GET",
|
||||
responses: {
|
||||
200: {
|
||||
bodyMapper: Mappers.OperationListResult
|
||||
},
|
||||
default: {
|
||||
bodyMapper: Mappers.CloudError
|
||||
}
|
||||
},
|
||||
queryParameters: [Parameters.apiVersion],
|
||||
urlParameters: [Parameters.$host],
|
||||
headerParameters: [Parameters.accept],
|
||||
serializer
|
||||
};
|
|
@ -0,0 +1,669 @@
|
|||
/*
|
||||
* Copyright (c) Microsoft Corporation.
|
||||
* Licensed under the MIT License.
|
||||
*
|
||||
* Code generated by Microsoft (R) AutoRest Code Generator.
|
||||
* Changes may cause incorrect behavior and will be lost if the code is regenerated.
|
||||
*/
|
||||
|
||||
import { PagedAsyncIterableIterator } from "@azure/core-paging";
|
||||
import { Spacecrafts } from "../operationsInterfaces";
|
||||
import * as coreClient from "@azure/core-client";
|
||||
import * as Mappers from "../models/mappers";
|
||||
import * as Parameters from "../models/parameters";
|
||||
import { AzureOrbitalContext } from "../azureOrbitalContext";
|
||||
import { PollerLike, PollOperationState, LroEngine } from "@azure/core-lro";
|
||||
import { LroImpl } from "../lroImpl";
|
||||
import {
|
||||
Spacecraft,
|
||||
SpacecraftsListBySubscriptionOptionalParams,
|
||||
SpacecraftsListOptionalParams,
|
||||
SpacecraftsListBySubscriptionResponse,
|
||||
SpacecraftsListResponse,
|
||||
SpacecraftsGetOptionalParams,
|
||||
SpacecraftsGetResponse,
|
||||
SpacecraftsCreateOrUpdateOptionalParams,
|
||||
SpacecraftsCreateOrUpdateResponse,
|
||||
SpacecraftsDeleteOptionalParams,
|
||||
TagsObject,
|
||||
SpacecraftsUpdateTagsOptionalParams,
|
||||
SpacecraftsUpdateTagsResponse,
|
||||
ResourceReference,
|
||||
SpacecraftsListAvailableContactsOptionalParams,
|
||||
SpacecraftsListAvailableContactsResponse
|
||||
} from "../models";
|
||||
|
||||
/// <reference lib="esnext.asynciterable" />
|
||||
/** Class containing Spacecrafts operations. */
|
||||
export class SpacecraftsImpl implements Spacecrafts {
|
||||
private readonly client: AzureOrbitalContext;
|
||||
|
||||
/**
|
||||
* Initialize a new instance of the class Spacecrafts class.
|
||||
* @param client Reference to the service client
|
||||
*/
|
||||
constructor(client: AzureOrbitalContext) {
|
||||
this.client = client;
|
||||
}
|
||||
|
||||
/**
|
||||
* Return list of spacecrafts
|
||||
* @param options The options parameters.
|
||||
*/
|
||||
public listBySubscription(
|
||||
options?: SpacecraftsListBySubscriptionOptionalParams
|
||||
): PagedAsyncIterableIterator<Spacecraft> {
|
||||
const iter = this.listBySubscriptionPagingAll(options);
|
||||
return {
|
||||
next() {
|
||||
return iter.next();
|
||||
},
|
||||
[Symbol.asyncIterator]() {
|
||||
return this;
|
||||
},
|
||||
byPage: () => {
|
||||
return this.listBySubscriptionPagingPage(options);
|
||||
}
|
||||
};
|
||||
}
|
||||
|
||||
private async *listBySubscriptionPagingPage(
|
||||
options?: SpacecraftsListBySubscriptionOptionalParams
|
||||
): AsyncIterableIterator<Spacecraft[]> {
|
||||
let result = await this._listBySubscription(options);
|
||||
yield result.value || [];
|
||||
}
|
||||
|
||||
private async *listBySubscriptionPagingAll(
|
||||
options?: SpacecraftsListBySubscriptionOptionalParams
|
||||
): AsyncIterableIterator<Spacecraft> {
|
||||
for await (const page of this.listBySubscriptionPagingPage(options)) {
|
||||
yield* page;
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Return list of spacecrafts
|
||||
* @param resourceGroupName The name of the resource group. The name is case insensitive.
|
||||
* @param options The options parameters.
|
||||
*/
|
||||
public list(
|
||||
resourceGroupName: string,
|
||||
options?: SpacecraftsListOptionalParams
|
||||
): PagedAsyncIterableIterator<Spacecraft> {
|
||||
const iter = this.listPagingAll(resourceGroupName, options);
|
||||
return {
|
||||
next() {
|
||||
return iter.next();
|
||||
},
|
||||
[Symbol.asyncIterator]() {
|
||||
return this;
|
||||
},
|
||||
byPage: () => {
|
||||
return this.listPagingPage(resourceGroupName, options);
|
||||
}
|
||||
};
|
||||
}
|
||||
|
||||
private async *listPagingPage(
|
||||
resourceGroupName: string,
|
||||
options?: SpacecraftsListOptionalParams
|
||||
): AsyncIterableIterator<Spacecraft[]> {
|
||||
let result = await this._list(resourceGroupName, options);
|
||||
yield result.value || [];
|
||||
}
|
||||
|
||||
private async *listPagingAll(
|
||||
resourceGroupName: string,
|
||||
options?: SpacecraftsListOptionalParams
|
||||
): AsyncIterableIterator<Spacecraft> {
|
||||
for await (const page of this.listPagingPage(resourceGroupName, options)) {
|
||||
yield* page;
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Return list of spacecrafts
|
||||
* @param options The options parameters.
|
||||
*/
|
||||
private _listBySubscription(
|
||||
options?: SpacecraftsListBySubscriptionOptionalParams
|
||||
): Promise<SpacecraftsListBySubscriptionResponse> {
|
||||
return this.client.sendOperationRequest(
|
||||
{ options },
|
||||
listBySubscriptionOperationSpec
|
||||
);
|
||||
}
|
||||
|
||||
/**
|
||||
* Return list of spacecrafts
|
||||
* @param resourceGroupName The name of the resource group. The name is case insensitive.
|
||||
* @param options The options parameters.
|
||||
*/
|
||||
private _list(
|
||||
resourceGroupName: string,
|
||||
options?: SpacecraftsListOptionalParams
|
||||
): Promise<SpacecraftsListResponse> {
|
||||
return this.client.sendOperationRequest(
|
||||
{ resourceGroupName, options },
|
||||
listOperationSpec
|
||||
);
|
||||
}
|
||||
|
||||
/**
|
||||
* Gets the specified spacecraft in a specified resource group
|
||||
* @param resourceGroupName The name of the resource group. The name is case insensitive.
|
||||
* @param spacecraftName Spacecraft ID
|
||||
* @param options The options parameters.
|
||||
*/
|
||||
get(
|
||||
resourceGroupName: string,
|
||||
spacecraftName: string,
|
||||
options?: SpacecraftsGetOptionalParams
|
||||
): Promise<SpacecraftsGetResponse> {
|
||||
return this.client.sendOperationRequest(
|
||||
{ resourceGroupName, spacecraftName, options },
|
||||
getOperationSpec
|
||||
);
|
||||
}
|
||||
|
||||
/**
|
||||
* Creates or updates a spacecraft resource
|
||||
* @param resourceGroupName The name of the resource group. The name is case insensitive.
|
||||
* @param spacecraftName Spacecraft ID
|
||||
* @param location The geo-location where the resource lives
|
||||
* @param options The options parameters.
|
||||
*/
|
||||
async beginCreateOrUpdate(
|
||||
resourceGroupName: string,
|
||||
spacecraftName: string,
|
||||
location: string,
|
||||
options?: SpacecraftsCreateOrUpdateOptionalParams
|
||||
): Promise<
|
||||
PollerLike<
|
||||
PollOperationState<SpacecraftsCreateOrUpdateResponse>,
|
||||
SpacecraftsCreateOrUpdateResponse
|
||||
>
|
||||
> {
|
||||
const directSendOperation = async (
|
||||
args: coreClient.OperationArguments,
|
||||
spec: coreClient.OperationSpec
|
||||
): Promise<SpacecraftsCreateOrUpdateResponse> => {
|
||||
return this.client.sendOperationRequest(args, spec);
|
||||
};
|
||||
const sendOperation = async (
|
||||
args: coreClient.OperationArguments,
|
||||
spec: coreClient.OperationSpec
|
||||
) => {
|
||||
let currentRawResponse:
|
||||
| coreClient.FullOperationResponse
|
||||
| undefined = undefined;
|
||||
const providedCallback = args.options?.onResponse;
|
||||
const callback: coreClient.RawResponseCallback = (
|
||||
rawResponse: coreClient.FullOperationResponse,
|
||||
flatResponse: unknown
|
||||
) => {
|
||||
currentRawResponse = rawResponse;
|
||||
providedCallback?.(rawResponse, flatResponse);
|
||||
};
|
||||
const updatedArgs = {
|
||||
...args,
|
||||
options: {
|
||||
...args.options,
|
||||
onResponse: callback
|
||||
}
|
||||
};
|
||||
const flatResponse = await directSendOperation(updatedArgs, spec);
|
||||
return {
|
||||
flatResponse,
|
||||
rawResponse: {
|
||||
statusCode: currentRawResponse!.status,
|
||||
body: currentRawResponse!.parsedBody,
|
||||
headers: currentRawResponse!.headers.toJSON()
|
||||
}
|
||||
};
|
||||
};
|
||||
|
||||
const lro = new LroImpl(
|
||||
sendOperation,
|
||||
{ resourceGroupName, spacecraftName, location, options },
|
||||
createOrUpdateOperationSpec
|
||||
);
|
||||
return new LroEngine(lro, {
|
||||
resumeFrom: options?.resumeFrom,
|
||||
intervalInMs: options?.updateIntervalInMs,
|
||||
lroResourceLocationConfig: "azure-async-operation"
|
||||
});
|
||||
}
|
||||
|
||||
/**
|
||||
* Creates or updates a spacecraft resource
|
||||
* @param resourceGroupName The name of the resource group. The name is case insensitive.
|
||||
* @param spacecraftName Spacecraft ID
|
||||
* @param location The geo-location where the resource lives
|
||||
* @param options The options parameters.
|
||||
*/
|
||||
async beginCreateOrUpdateAndWait(
|
||||
resourceGroupName: string,
|
||||
spacecraftName: string,
|
||||
location: string,
|
||||
options?: SpacecraftsCreateOrUpdateOptionalParams
|
||||
): Promise<SpacecraftsCreateOrUpdateResponse> {
|
||||
const poller = await this.beginCreateOrUpdate(
|
||||
resourceGroupName,
|
||||
spacecraftName,
|
||||
location,
|
||||
options
|
||||
);
|
||||
return poller.pollUntilDone();
|
||||
}
|
||||
|
||||
/**
|
||||
* Deletes a specified spacecraft resource.
|
||||
* @param resourceGroupName The name of the resource group. The name is case insensitive.
|
||||
* @param spacecraftName Spacecraft ID
|
||||
* @param options The options parameters.
|
||||
*/
|
||||
async beginDelete(
|
||||
resourceGroupName: string,
|
||||
spacecraftName: string,
|
||||
options?: SpacecraftsDeleteOptionalParams
|
||||
): Promise<PollerLike<PollOperationState<void>, void>> {
|
||||
const directSendOperation = async (
|
||||
args: coreClient.OperationArguments,
|
||||
spec: coreClient.OperationSpec
|
||||
): Promise<void> => {
|
||||
return this.client.sendOperationRequest(args, spec);
|
||||
};
|
||||
const sendOperation = async (
|
||||
args: coreClient.OperationArguments,
|
||||
spec: coreClient.OperationSpec
|
||||
) => {
|
||||
let currentRawResponse:
|
||||
| coreClient.FullOperationResponse
|
||||
| undefined = undefined;
|
||||
const providedCallback = args.options?.onResponse;
|
||||
const callback: coreClient.RawResponseCallback = (
|
||||
rawResponse: coreClient.FullOperationResponse,
|
||||
flatResponse: unknown
|
||||
) => {
|
||||
currentRawResponse = rawResponse;
|
||||
providedCallback?.(rawResponse, flatResponse);
|
||||
};
|
||||
const updatedArgs = {
|
||||
...args,
|
||||
options: {
|
||||
...args.options,
|
||||
onResponse: callback
|
||||
}
|
||||
};
|
||||
const flatResponse = await directSendOperation(updatedArgs, spec);
|
||||
return {
|
||||
flatResponse,
|
||||
rawResponse: {
|
||||
statusCode: currentRawResponse!.status,
|
||||
body: currentRawResponse!.parsedBody,
|
||||
headers: currentRawResponse!.headers.toJSON()
|
||||
}
|
||||
};
|
||||
};
|
||||
|
||||
const lro = new LroImpl(
|
||||
sendOperation,
|
||||
{ resourceGroupName, spacecraftName, options },
|
||||
deleteOperationSpec
|
||||
);
|
||||
return new LroEngine(lro, {
|
||||
resumeFrom: options?.resumeFrom,
|
||||
intervalInMs: options?.updateIntervalInMs,
|
||||
lroResourceLocationConfig: "location"
|
||||
});
|
||||
}
|
||||
|
||||
/**
|
||||
* Deletes a specified spacecraft resource.
|
||||
* @param resourceGroupName The name of the resource group. The name is case insensitive.
|
||||
* @param spacecraftName Spacecraft ID
|
||||
* @param options The options parameters.
|
||||
*/
|
||||
async beginDeleteAndWait(
|
||||
resourceGroupName: string,
|
||||
spacecraftName: string,
|
||||
options?: SpacecraftsDeleteOptionalParams
|
||||
): Promise<void> {
|
||||
const poller = await this.beginDelete(
|
||||
resourceGroupName,
|
||||
spacecraftName,
|
||||
options
|
||||
);
|
||||
return poller.pollUntilDone();
|
||||
}
|
||||
|
||||
/**
|
||||
* Updates the specified spacecraft tags.
|
||||
* @param resourceGroupName The name of the resource group. The name is case insensitive.
|
||||
* @param spacecraftName Spacecraft ID
|
||||
* @param parameters Parameters supplied to update spacecraft tags.
|
||||
* @param options The options parameters.
|
||||
*/
|
||||
updateTags(
|
||||
resourceGroupName: string,
|
||||
spacecraftName: string,
|
||||
parameters: TagsObject,
|
||||
options?: SpacecraftsUpdateTagsOptionalParams
|
||||
): Promise<SpacecraftsUpdateTagsResponse> {
|
||||
return this.client.sendOperationRequest(
|
||||
{ resourceGroupName, spacecraftName, parameters, options },
|
||||
updateTagsOperationSpec
|
||||
);
|
||||
}
|
||||
|
||||
/**
|
||||
* Return list of available contacts
|
||||
* @param resourceGroupName The name of the resource group. The name is case insensitive.
|
||||
* @param spacecraftName Spacecraft ID
|
||||
* @param contactProfile The reference to the contact profile resource.
|
||||
* @param groundStationName Name of Azure Ground Station.
|
||||
* @param startTime Start time of a contact.
|
||||
* @param endTime End time of a contact.
|
||||
* @param options The options parameters.
|
||||
*/
|
||||
async beginListAvailableContacts(
|
||||
resourceGroupName: string,
|
||||
spacecraftName: string,
|
||||
contactProfile: ResourceReference,
|
||||
groundStationName: string,
|
||||
startTime: Date,
|
||||
endTime: Date,
|
||||
options?: SpacecraftsListAvailableContactsOptionalParams
|
||||
): Promise<
|
||||
PollerLike<
|
||||
PollOperationState<SpacecraftsListAvailableContactsResponse>,
|
||||
SpacecraftsListAvailableContactsResponse
|
||||
>
|
||||
> {
|
||||
const directSendOperation = async (
|
||||
args: coreClient.OperationArguments,
|
||||
spec: coreClient.OperationSpec
|
||||
): Promise<SpacecraftsListAvailableContactsResponse> => {
|
||||
return this.client.sendOperationRequest(args, spec);
|
||||
};
|
||||
const sendOperation = async (
|
||||
args: coreClient.OperationArguments,
|
||||
spec: coreClient.OperationSpec
|
||||
) => {
|
||||
let currentRawResponse:
|
||||
| coreClient.FullOperationResponse
|
||||
| undefined = undefined;
|
||||
const providedCallback = args.options?.onResponse;
|
||||
const callback: coreClient.RawResponseCallback = (
|
||||
rawResponse: coreClient.FullOperationResponse,
|
||||
flatResponse: unknown
|
||||
) => {
|
||||
currentRawResponse = rawResponse;
|
||||
providedCallback?.(rawResponse, flatResponse);
|
||||
};
|
||||
const updatedArgs = {
|
||||
...args,
|
||||
options: {
|
||||
...args.options,
|
||||
onResponse: callback
|
||||
}
|
||||
};
|
||||
const flatResponse = await directSendOperation(updatedArgs, spec);
|
||||
return {
|
||||
flatResponse,
|
||||
rawResponse: {
|
||||
statusCode: currentRawResponse!.status,
|
||||
body: currentRawResponse!.parsedBody,
|
||||
headers: currentRawResponse!.headers.toJSON()
|
||||
}
|
||||
};
|
||||
};
|
||||
|
||||
const lro = new LroImpl(
|
||||
sendOperation,
|
||||
{
|
||||
resourceGroupName,
|
||||
spacecraftName,
|
||||
contactProfile,
|
||||
groundStationName,
|
||||
startTime,
|
||||
endTime,
|
||||
options
|
||||
},
|
||||
listAvailableContactsOperationSpec
|
||||
);
|
||||
return new LroEngine(lro, {
|
||||
resumeFrom: options?.resumeFrom,
|
||||
intervalInMs: options?.updateIntervalInMs,
|
||||
lroResourceLocationConfig: "azure-async-operation"
|
||||
});
|
||||
}
|
||||
|
||||
/**
|
||||
* Return list of available contacts
|
||||
* @param resourceGroupName The name of the resource group. The name is case insensitive.
|
||||
* @param spacecraftName Spacecraft ID
|
||||
* @param contactProfile The reference to the contact profile resource.
|
||||
* @param groundStationName Name of Azure Ground Station.
|
||||
* @param startTime Start time of a contact.
|
||||
* @param endTime End time of a contact.
|
||||
* @param options The options parameters.
|
||||
*/
|
||||
async beginListAvailableContactsAndWait(
|
||||
resourceGroupName: string,
|
||||
spacecraftName: string,
|
||||
contactProfile: ResourceReference,
|
||||
groundStationName: string,
|
||||
startTime: Date,
|
||||
endTime: Date,
|
||||
options?: SpacecraftsListAvailableContactsOptionalParams
|
||||
): Promise<SpacecraftsListAvailableContactsResponse> {
|
||||
const poller = await this.beginListAvailableContacts(
|
||||
resourceGroupName,
|
||||
spacecraftName,
|
||||
contactProfile,
|
||||
groundStationName,
|
||||
startTime,
|
||||
endTime,
|
||||
options
|
||||
);
|
||||
return poller.pollUntilDone();
|
||||
}
|
||||
}
|
||||
// Operation Specifications
|
||||
const serializer = coreClient.createSerializer(Mappers, /* isXml */ false);
|
||||
|
||||
const listBySubscriptionOperationSpec: coreClient.OperationSpec = {
|
||||
path:
|
||||
"/subscriptions/{subscriptionId}/providers/Microsoft.Orbital/spacecrafts",
|
||||
httpMethod: "GET",
|
||||
responses: {
|
||||
200: {
|
||||
bodyMapper: Mappers.SpacecraftListResult
|
||||
},
|
||||
default: {
|
||||
bodyMapper: Mappers.CloudError
|
||||
}
|
||||
},
|
||||
queryParameters: [Parameters.apiVersion],
|
||||
urlParameters: [Parameters.$host, Parameters.subscriptionId],
|
||||
headerParameters: [Parameters.accept],
|
||||
serializer
|
||||
};
|
||||
const listOperationSpec: coreClient.OperationSpec = {
|
||||
path:
|
||||
"/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Orbital/spacecrafts",
|
||||
httpMethod: "GET",
|
||||
responses: {
|
||||
200: {
|
||||
bodyMapper: Mappers.SpacecraftListResult
|
||||
},
|
||||
default: {
|
||||
bodyMapper: Mappers.CloudError
|
||||
}
|
||||
},
|
||||
queryParameters: [Parameters.apiVersion],
|
||||
urlParameters: [
|
||||
Parameters.$host,
|
||||
Parameters.subscriptionId,
|
||||
Parameters.resourceGroupName
|
||||
],
|
||||
headerParameters: [Parameters.accept],
|
||||
serializer
|
||||
};
|
||||
const getOperationSpec: coreClient.OperationSpec = {
|
||||
path:
|
||||
"/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Orbital/spacecrafts/{spacecraftName}",
|
||||
httpMethod: "GET",
|
||||
responses: {
|
||||
200: {
|
||||
bodyMapper: Mappers.Spacecraft
|
||||
},
|
||||
default: {
|
||||
bodyMapper: Mappers.CloudError
|
||||
}
|
||||
},
|
||||
queryParameters: [Parameters.apiVersion],
|
||||
urlParameters: [
|
||||
Parameters.$host,
|
||||
Parameters.subscriptionId,
|
||||
Parameters.resourceGroupName,
|
||||
Parameters.spacecraftName
|
||||
],
|
||||
headerParameters: [Parameters.accept],
|
||||
serializer
|
||||
};
|
||||
const createOrUpdateOperationSpec: coreClient.OperationSpec = {
|
||||
path:
|
||||
"/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Orbital/spacecrafts/{spacecraftName}",
|
||||
httpMethod: "PUT",
|
||||
responses: {
|
||||
200: {
|
||||
bodyMapper: Mappers.Spacecraft
|
||||
},
|
||||
201: {
|
||||
bodyMapper: Mappers.Spacecraft
|
||||
},
|
||||
202: {
|
||||
bodyMapper: Mappers.Spacecraft
|
||||
},
|
||||
204: {
|
||||
bodyMapper: Mappers.Spacecraft
|
||||
},
|
||||
default: {
|
||||
bodyMapper: Mappers.CloudError
|
||||
}
|
||||
},
|
||||
requestBody: {
|
||||
parameterPath: {
|
||||
tags: ["options", "tags"],
|
||||
location: ["location"],
|
||||
noradId: ["options", "noradId"],
|
||||
titleLine: ["options", "titleLine"],
|
||||
tleLine1: ["options", "tleLine1"],
|
||||
tleLine2: ["options", "tleLine2"],
|
||||
links: ["options", "links"]
|
||||
},
|
||||
mapper: { ...Mappers.Spacecraft, required: true }
|
||||
},
|
||||
queryParameters: [Parameters.apiVersion],
|
||||
urlParameters: [
|
||||
Parameters.$host,
|
||||
Parameters.subscriptionId,
|
||||
Parameters.resourceGroupName,
|
||||
Parameters.spacecraftName
|
||||
],
|
||||
headerParameters: [Parameters.accept, Parameters.contentType],
|
||||
mediaType: "json",
|
||||
serializer
|
||||
};
|
||||
const deleteOperationSpec: coreClient.OperationSpec = {
|
||||
path:
|
||||
"/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Orbital/spacecrafts/{spacecraftName}",
|
||||
httpMethod: "DELETE",
|
||||
responses: {
|
||||
200: {},
|
||||
201: {},
|
||||
202: {},
|
||||
204: {},
|
||||
default: {
|
||||
bodyMapper: Mappers.CloudError
|
||||
}
|
||||
},
|
||||
queryParameters: [Parameters.apiVersion],
|
||||
urlParameters: [
|
||||
Parameters.$host,
|
||||
Parameters.subscriptionId,
|
||||
Parameters.resourceGroupName,
|
||||
Parameters.spacecraftName
|
||||
],
|
||||
headerParameters: [Parameters.accept],
|
||||
serializer
|
||||
};
|
||||
const updateTagsOperationSpec: coreClient.OperationSpec = {
|
||||
path:
|
||||
"/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Orbital/spacecrafts/{spacecraftName}",
|
||||
httpMethod: "PATCH",
|
||||
responses: {
|
||||
200: {
|
||||
bodyMapper: Mappers.Spacecraft
|
||||
},
|
||||
default: {
|
||||
bodyMapper: Mappers.CloudError
|
||||
}
|
||||
},
|
||||
requestBody: Parameters.parameters1,
|
||||
queryParameters: [Parameters.apiVersion],
|
||||
urlParameters: [
|
||||
Parameters.$host,
|
||||
Parameters.subscriptionId,
|
||||
Parameters.resourceGroupName,
|
||||
Parameters.spacecraftName
|
||||
],
|
||||
headerParameters: [Parameters.accept, Parameters.contentType],
|
||||
mediaType: "json",
|
||||
serializer
|
||||
};
|
||||
const listAvailableContactsOperationSpec: coreClient.OperationSpec = {
|
||||
path:
|
||||
"/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Orbital/spacecrafts/{spacecraftName}/listAvailableContacts",
|
||||
httpMethod: "POST",
|
||||
responses: {
|
||||
200: {
|
||||
bodyMapper: Mappers.AvailableContactsListResult
|
||||
},
|
||||
201: {
|
||||
bodyMapper: Mappers.AvailableContactsListResult
|
||||
},
|
||||
202: {
|
||||
bodyMapper: Mappers.AvailableContactsListResult
|
||||
},
|
||||
204: {
|
||||
bodyMapper: Mappers.AvailableContactsListResult
|
||||
},
|
||||
default: {
|
||||
bodyMapper: Mappers.CloudError
|
||||
}
|
||||
},
|
||||
requestBody: {
|
||||
parameterPath: {
|
||||
contactProfile: ["contactProfile"],
|
||||
groundStationName: ["groundStationName"],
|
||||
startTime: ["startTime"],
|
||||
endTime: ["endTime"]
|
||||
},
|
||||
mapper: { ...Mappers.ContactParameters, required: true }
|
||||
},
|
||||
queryParameters: [Parameters.apiVersion],
|
||||
urlParameters: [
|
||||
Parameters.$host,
|
||||
Parameters.subscriptionId,
|
||||
Parameters.resourceGroupName,
|
||||
Parameters.spacecraftName
|
||||
],
|
||||
headerParameters: [Parameters.accept, Parameters.contentType],
|
||||
mediaType: "json",
|
||||
serializer
|
||||
};
|
|
@ -0,0 +1,39 @@
|
|||
/*
|
||||
* Copyright (c) Microsoft Corporation.
|
||||
* Licensed under the MIT License.
|
||||
*
|
||||
* Code generated by Microsoft (R) AutoRest Code Generator.
|
||||
* Changes may cause incorrect behavior and will be lost if the code is regenerated.
|
||||
*/
|
||||
|
||||
import { PagedAsyncIterableIterator } from "@azure/core-paging";
|
||||
import {
|
||||
AvailableGroundStation,
|
||||
Enum6,
|
||||
AvailableGroundStationsListByCapabilityOptionalParams,
|
||||
AvailableGroundStationsGetOptionalParams,
|
||||
AvailableGroundStationsGetResponse
|
||||
} from "../models";
|
||||
|
||||
/// <reference lib="esnext.asynciterable" />
|
||||
/** Interface representing a AvailableGroundStations. */
|
||||
export interface AvailableGroundStations {
|
||||
/**
|
||||
* Returns list of available ground stations
|
||||
* @param capability Ground Station Capability
|
||||
* @param options The options parameters.
|
||||
*/
|
||||
listByCapability(
|
||||
capability: Enum6,
|
||||
options?: AvailableGroundStationsListByCapabilityOptionalParams
|
||||
): PagedAsyncIterableIterator<AvailableGroundStation>;
|
||||
/**
|
||||
* Gets the specified available ground station
|
||||
* @param groundStationName Ground Station name
|
||||
* @param options The options parameters.
|
||||
*/
|
||||
get(
|
||||
groundStationName: string,
|
||||
options?: AvailableGroundStationsGetOptionalParams
|
||||
): Promise<AvailableGroundStationsGetResponse>;
|
||||
}
|
|
@ -0,0 +1,121 @@
|
|||
/*
|
||||
* Copyright (c) Microsoft Corporation.
|
||||
* Licensed under the MIT License.
|
||||
*
|
||||
* Code generated by Microsoft (R) AutoRest Code Generator.
|
||||
* Changes may cause incorrect behavior and will be lost if the code is regenerated.
|
||||
*/
|
||||
|
||||
import { PagedAsyncIterableIterator } from "@azure/core-paging";
|
||||
import { PollerLike, PollOperationState } from "@azure/core-lro";
|
||||
import {
|
||||
ContactProfile,
|
||||
ContactProfilesListBySubscriptionOptionalParams,
|
||||
ContactProfilesListOptionalParams,
|
||||
ContactProfilesGetOptionalParams,
|
||||
ContactProfilesGetResponse,
|
||||
ContactProfilesCreateOrUpdateOptionalParams,
|
||||
ContactProfilesCreateOrUpdateResponse,
|
||||
ContactProfilesDeleteOptionalParams,
|
||||
TagsObject,
|
||||
ContactProfilesUpdateTagsOptionalParams,
|
||||
ContactProfilesUpdateTagsResponse
|
||||
} from "../models";
|
||||
|
||||
/// <reference lib="esnext.asynciterable" />
|
||||
/** Interface representing a ContactProfiles. */
|
||||
export interface ContactProfiles {
|
||||
/**
|
||||
* Returns list of contact profiles
|
||||
* @param options The options parameters.
|
||||
*/
|
||||
listBySubscription(
|
||||
options?: ContactProfilesListBySubscriptionOptionalParams
|
||||
): PagedAsyncIterableIterator<ContactProfile>;
|
||||
/**
|
||||
* Returns list of contact profiles
|
||||
* @param resourceGroupName The name of the resource group. The name is case insensitive.
|
||||
* @param options The options parameters.
|
||||
*/
|
||||
list(
|
||||
resourceGroupName: string,
|
||||
options?: ContactProfilesListOptionalParams
|
||||
): PagedAsyncIterableIterator<ContactProfile>;
|
||||
/**
|
||||
* Gets the specified contact Profile in a specified resource group
|
||||
* @param resourceGroupName The name of the resource group. The name is case insensitive.
|
||||
* @param contactProfileName Contact Profile Name
|
||||
* @param options The options parameters.
|
||||
*/
|
||||
get(
|
||||
resourceGroupName: string,
|
||||
contactProfileName: string,
|
||||
options?: ContactProfilesGetOptionalParams
|
||||
): Promise<ContactProfilesGetResponse>;
|
||||
/**
|
||||
* Creates or updates a contact profile
|
||||
* @param resourceGroupName The name of the resource group. The name is case insensitive.
|
||||
* @param contactProfileName Contact Profile Name
|
||||
* @param location The geo-location where the resource lives
|
||||
* @param options The options parameters.
|
||||
*/
|
||||
beginCreateOrUpdate(
|
||||
resourceGroupName: string,
|
||||
contactProfileName: string,
|
||||
location: string,
|
||||
options?: ContactProfilesCreateOrUpdateOptionalParams
|
||||
): Promise<
|
||||
PollerLike<
|
||||
PollOperationState<ContactProfilesCreateOrUpdateResponse>,
|
||||
ContactProfilesCreateOrUpdateResponse
|
||||
>
|
||||
>;
|
||||
/**
|
||||
* Creates or updates a contact profile
|
||||
* @param resourceGroupName The name of the resource group. The name is case insensitive.
|
||||
* @param contactProfileName Contact Profile Name
|
||||
* @param location The geo-location where the resource lives
|
||||
* @param options The options parameters.
|
||||
*/
|
||||
beginCreateOrUpdateAndWait(
|
||||
resourceGroupName: string,
|
||||
contactProfileName: string,
|
||||
location: string,
|
||||
options?: ContactProfilesCreateOrUpdateOptionalParams
|
||||
): Promise<ContactProfilesCreateOrUpdateResponse>;
|
||||
/**
|
||||
* Deletes a specified contact profile resource.
|
||||
* @param resourceGroupName The name of the resource group. The name is case insensitive.
|
||||
* @param contactProfileName Contact Profile Name
|
||||
* @param options The options parameters.
|
||||
*/
|
||||
beginDelete(
|
||||
resourceGroupName: string,
|
||||
contactProfileName: string,
|
||||
options?: ContactProfilesDeleteOptionalParams
|
||||
): Promise<PollerLike<PollOperationState<void>, void>>;
|
||||
/**
|
||||
* Deletes a specified contact profile resource.
|
||||
* @param resourceGroupName The name of the resource group. The name is case insensitive.
|
||||
* @param contactProfileName Contact Profile Name
|
||||
* @param options The options parameters.
|
||||
*/
|
||||
beginDeleteAndWait(
|
||||
resourceGroupName: string,
|
||||
contactProfileName: string,
|
||||
options?: ContactProfilesDeleteOptionalParams
|
||||
): Promise<void>;
|
||||
/**
|
||||
* Updates the specified contact profile tags.
|
||||
* @param resourceGroupName The name of the resource group. The name is case insensitive.
|
||||
* @param contactProfileName Contact Profile Name
|
||||
* @param parameters Parameters supplied to update contact profile tags.
|
||||
* @param options The options parameters.
|
||||
*/
|
||||
updateTags(
|
||||
resourceGroupName: string,
|
||||
contactProfileName: string,
|
||||
parameters: TagsObject,
|
||||
options?: ContactProfilesUpdateTagsOptionalParams
|
||||
): Promise<ContactProfilesUpdateTagsResponse>;
|
||||
}
|
|
@ -0,0 +1,109 @@
|
|||
/*
|
||||
* Copyright (c) Microsoft Corporation.
|
||||
* Licensed under the MIT License.
|
||||
*
|
||||
* Code generated by Microsoft (R) AutoRest Code Generator.
|
||||
* Changes may cause incorrect behavior and will be lost if the code is regenerated.
|
||||
*/
|
||||
|
||||
import { PagedAsyncIterableIterator } from "@azure/core-paging";
|
||||
import { PollerLike, PollOperationState } from "@azure/core-lro";
|
||||
import {
|
||||
Contact,
|
||||
ContactsListOptionalParams,
|
||||
ContactsGetOptionalParams,
|
||||
ContactsGetResponse,
|
||||
ContactsCreateOptionalParams,
|
||||
ContactsCreateResponse,
|
||||
ContactsDeleteOptionalParams
|
||||
} from "../models";
|
||||
|
||||
/// <reference lib="esnext.asynciterable" />
|
||||
/** Interface representing a Contacts. */
|
||||
export interface Contacts {
|
||||
/**
|
||||
* Returns list of contacts by spacecraftName
|
||||
* @param resourceGroupName The name of the resource group. The name is case insensitive.
|
||||
* @param spacecraftName Spacecraft ID
|
||||
* @param options The options parameters.
|
||||
*/
|
||||
list(
|
||||
resourceGroupName: string,
|
||||
spacecraftName: string,
|
||||
options?: ContactsListOptionalParams
|
||||
): PagedAsyncIterableIterator<Contact>;
|
||||
/**
|
||||
* Gets the specified contact in a specified resource group
|
||||
* @param resourceGroupName The name of the resource group. The name is case insensitive.
|
||||
* @param spacecraftName Spacecraft ID
|
||||
* @param contactName Contact Name
|
||||
* @param options The options parameters.
|
||||
*/
|
||||
get(
|
||||
resourceGroupName: string,
|
||||
spacecraftName: string,
|
||||
contactName: string,
|
||||
options?: ContactsGetOptionalParams
|
||||
): Promise<ContactsGetResponse>;
|
||||
/**
|
||||
* Creates a contact.
|
||||
* @param resourceGroupName The name of the resource group. The name is case insensitive.
|
||||
* @param spacecraftName Spacecraft ID
|
||||
* @param contactName Contact Name
|
||||
* @param parameters The parameters to provide for the created contact.
|
||||
* @param options The options parameters.
|
||||
*/
|
||||
beginCreate(
|
||||
resourceGroupName: string,
|
||||
spacecraftName: string,
|
||||
contactName: string,
|
||||
parameters: Contact,
|
||||
options?: ContactsCreateOptionalParams
|
||||
): Promise<
|
||||
PollerLike<
|
||||
PollOperationState<ContactsCreateResponse>,
|
||||
ContactsCreateResponse
|
||||
>
|
||||
>;
|
||||
/**
|
||||
* Creates a contact.
|
||||
* @param resourceGroupName The name of the resource group. The name is case insensitive.
|
||||
* @param spacecraftName Spacecraft ID
|
||||
* @param contactName Contact Name
|
||||
* @param parameters The parameters to provide for the created contact.
|
||||
* @param options The options parameters.
|
||||
*/
|
||||
beginCreateAndWait(
|
||||
resourceGroupName: string,
|
||||
spacecraftName: string,
|
||||
contactName: string,
|
||||
parameters: Contact,
|
||||
options?: ContactsCreateOptionalParams
|
||||
): Promise<ContactsCreateResponse>;
|
||||
/**
|
||||
* Deletes a specified contact
|
||||
* @param resourceGroupName The name of the resource group. The name is case insensitive.
|
||||
* @param spacecraftName Spacecraft ID
|
||||
* @param contactName Contact Name
|
||||
* @param options The options parameters.
|
||||
*/
|
||||
beginDelete(
|
||||
resourceGroupName: string,
|
||||
spacecraftName: string,
|
||||
contactName: string,
|
||||
options?: ContactsDeleteOptionalParams
|
||||
): Promise<PollerLike<PollOperationState<void>, void>>;
|
||||
/**
|
||||
* Deletes a specified contact
|
||||
* @param resourceGroupName The name of the resource group. The name is case insensitive.
|
||||
* @param spacecraftName Spacecraft ID
|
||||
* @param contactName Contact Name
|
||||
* @param options The options parameters.
|
||||
*/
|
||||
beginDeleteAndWait(
|
||||
resourceGroupName: string,
|
||||
spacecraftName: string,
|
||||
contactName: string,
|
||||
options?: ContactsDeleteOptionalParams
|
||||
): Promise<void>;
|
||||
}
|
|
@ -0,0 +1,13 @@
|
|||
/*
|
||||
* Copyright (c) Microsoft Corporation.
|
||||
* Licensed under the MIT License.
|
||||
*
|
||||
* Code generated by Microsoft (R) AutoRest Code Generator.
|
||||
* Changes may cause incorrect behavior and will be lost if the code is regenerated.
|
||||
*/
|
||||
|
||||
export * from "./operations";
|
||||
export * from "./spacecrafts";
|
||||
export * from "./contacts";
|
||||
export * from "./contactProfiles";
|
||||
export * from "./availableGroundStations";
|
|
@ -0,0 +1,22 @@
|
|||
/*
|
||||
* Copyright (c) Microsoft Corporation.
|
||||
* Licensed under the MIT License.
|
||||
*
|
||||
* Code generated by Microsoft (R) AutoRest Code Generator.
|
||||
* Changes may cause incorrect behavior and will be lost if the code is regenerated.
|
||||
*/
|
||||
|
||||
import { PagedAsyncIterableIterator } from "@azure/core-paging";
|
||||
import { Operation, OperationsListOptionalParams } from "../models";
|
||||
|
||||
/// <reference lib="esnext.asynciterable" />
|
||||
/** Interface representing a Operations. */
|
||||
export interface Operations {
|
||||
/**
|
||||
* Lists all of the available Orbital Rest API operations.
|
||||
* @param options The options parameters.
|
||||
*/
|
||||
list(
|
||||
options?: OperationsListOptionalParams
|
||||
): PagedAsyncIterableIterator<Operation>;
|
||||
}
|
|
@ -0,0 +1,167 @@
|
|||
/*
|
||||
* Copyright (c) Microsoft Corporation.
|
||||
* Licensed under the MIT License.
|
||||
*
|
||||
* Code generated by Microsoft (R) AutoRest Code Generator.
|
||||
* Changes may cause incorrect behavior and will be lost if the code is regenerated.
|
||||
*/
|
||||
|
||||
import { PagedAsyncIterableIterator } from "@azure/core-paging";
|
||||
import { PollerLike, PollOperationState } from "@azure/core-lro";
|
||||
import {
|
||||
Spacecraft,
|
||||
SpacecraftsListBySubscriptionOptionalParams,
|
||||
SpacecraftsListOptionalParams,
|
||||
SpacecraftsGetOptionalParams,
|
||||
SpacecraftsGetResponse,
|
||||
SpacecraftsCreateOrUpdateOptionalParams,
|
||||
SpacecraftsCreateOrUpdateResponse,
|
||||
SpacecraftsDeleteOptionalParams,
|
||||
TagsObject,
|
||||
SpacecraftsUpdateTagsOptionalParams,
|
||||
SpacecraftsUpdateTagsResponse,
|
||||
ResourceReference,
|
||||
SpacecraftsListAvailableContactsOptionalParams,
|
||||
SpacecraftsListAvailableContactsResponse
|
||||
} from "../models";
|
||||
|
||||
/// <reference lib="esnext.asynciterable" />
|
||||
/** Interface representing a Spacecrafts. */
|
||||
export interface Spacecrafts {
|
||||
/**
|
||||
* Return list of spacecrafts
|
||||
* @param options The options parameters.
|
||||
*/
|
||||
listBySubscription(
|
||||
options?: SpacecraftsListBySubscriptionOptionalParams
|
||||
): PagedAsyncIterableIterator<Spacecraft>;
|
||||
/**
|
||||
* Return list of spacecrafts
|
||||
* @param resourceGroupName The name of the resource group. The name is case insensitive.
|
||||
* @param options The options parameters.
|
||||
*/
|
||||
list(
|
||||
resourceGroupName: string,
|
||||
options?: SpacecraftsListOptionalParams
|
||||
): PagedAsyncIterableIterator<Spacecraft>;
|
||||
/**
|
||||
* Gets the specified spacecraft in a specified resource group
|
||||
* @param resourceGroupName The name of the resource group. The name is case insensitive.
|
||||
* @param spacecraftName Spacecraft ID
|
||||
* @param options The options parameters.
|
||||
*/
|
||||
get(
|
||||
resourceGroupName: string,
|
||||
spacecraftName: string,
|
||||
options?: SpacecraftsGetOptionalParams
|
||||
): Promise<SpacecraftsGetResponse>;
|
||||
/**
|
||||
* Creates or updates a spacecraft resource
|
||||
* @param resourceGroupName The name of the resource group. The name is case insensitive.
|
||||
* @param spacecraftName Spacecraft ID
|
||||
* @param location The geo-location where the resource lives
|
||||
* @param options The options parameters.
|
||||
*/
|
||||
beginCreateOrUpdate(
|
||||
resourceGroupName: string,
|
||||
spacecraftName: string,
|
||||
location: string,
|
||||
options?: SpacecraftsCreateOrUpdateOptionalParams
|
||||
): Promise<
|
||||
PollerLike<
|
||||
PollOperationState<SpacecraftsCreateOrUpdateResponse>,
|
||||
SpacecraftsCreateOrUpdateResponse
|
||||
>
|
||||
>;
|
||||
/**
|
||||
* Creates or updates a spacecraft resource
|
||||
* @param resourceGroupName The name of the resource group. The name is case insensitive.
|
||||
* @param spacecraftName Spacecraft ID
|
||||
* @param location The geo-location where the resource lives
|
||||
* @param options The options parameters.
|
||||
*/
|
||||
beginCreateOrUpdateAndWait(
|
||||
resourceGroupName: string,
|
||||
spacecraftName: string,
|
||||
location: string,
|
||||
options?: SpacecraftsCreateOrUpdateOptionalParams
|
||||
): Promise<SpacecraftsCreateOrUpdateResponse>;
|
||||
/**
|
||||
* Deletes a specified spacecraft resource.
|
||||
* @param resourceGroupName The name of the resource group. The name is case insensitive.
|
||||
* @param spacecraftName Spacecraft ID
|
||||
* @param options The options parameters.
|
||||
*/
|
||||
beginDelete(
|
||||
resourceGroupName: string,
|
||||
spacecraftName: string,
|
||||
options?: SpacecraftsDeleteOptionalParams
|
||||
): Promise<PollerLike<PollOperationState<void>, void>>;
|
||||
/**
|
||||
* Deletes a specified spacecraft resource.
|
||||
* @param resourceGroupName The name of the resource group. The name is case insensitive.
|
||||
* @param spacecraftName Spacecraft ID
|
||||
* @param options The options parameters.
|
||||
*/
|
||||
beginDeleteAndWait(
|
||||
resourceGroupName: string,
|
||||
spacecraftName: string,
|
||||
options?: SpacecraftsDeleteOptionalParams
|
||||
): Promise<void>;
|
||||
/**
|
||||
* Updates the specified spacecraft tags.
|
||||
* @param resourceGroupName The name of the resource group. The name is case insensitive.
|
||||
* @param spacecraftName Spacecraft ID
|
||||
* @param parameters Parameters supplied to update spacecraft tags.
|
||||
* @param options The options parameters.
|
||||
*/
|
||||
updateTags(
|
||||
resourceGroupName: string,
|
||||
spacecraftName: string,
|
||||
parameters: TagsObject,
|
||||
options?: SpacecraftsUpdateTagsOptionalParams
|
||||
): Promise<SpacecraftsUpdateTagsResponse>;
|
||||
/**
|
||||
* Return list of available contacts
|
||||
* @param resourceGroupName The name of the resource group. The name is case insensitive.
|
||||
* @param spacecraftName Spacecraft ID
|
||||
* @param contactProfile The reference to the contact profile resource.
|
||||
* @param groundStationName Name of Azure Ground Station.
|
||||
* @param startTime Start time of a contact.
|
||||
* @param endTime End time of a contact.
|
||||
* @param options The options parameters.
|
||||
*/
|
||||
beginListAvailableContacts(
|
||||
resourceGroupName: string,
|
||||
spacecraftName: string,
|
||||
contactProfile: ResourceReference,
|
||||
groundStationName: string,
|
||||
startTime: Date,
|
||||
endTime: Date,
|
||||
options?: SpacecraftsListAvailableContactsOptionalParams
|
||||
): Promise<
|
||||
PollerLike<
|
||||
PollOperationState<SpacecraftsListAvailableContactsResponse>,
|
||||
SpacecraftsListAvailableContactsResponse
|
||||
>
|
||||
>;
|
||||
/**
|
||||
* Return list of available contacts
|
||||
* @param resourceGroupName The name of the resource group. The name is case insensitive.
|
||||
* @param spacecraftName Spacecraft ID
|
||||
* @param contactProfile The reference to the contact profile resource.
|
||||
* @param groundStationName Name of Azure Ground Station.
|
||||
* @param startTime Start time of a contact.
|
||||
* @param endTime End time of a contact.
|
||||
* @param options The options parameters.
|
||||
*/
|
||||
beginListAvailableContactsAndWait(
|
||||
resourceGroupName: string,
|
||||
spacecraftName: string,
|
||||
contactProfile: ResourceReference,
|
||||
groundStationName: string,
|
||||
startTime: Date,
|
||||
endTime: Date,
|
||||
options?: SpacecraftsListAvailableContactsOptionalParams
|
||||
): Promise<SpacecraftsListAvailableContactsResponse>;
|
||||
}
|
|
@ -0,0 +1,48 @@
|
|||
/*
|
||||
* Copyright (c) Microsoft Corporation.
|
||||
* Licensed under the MIT License.
|
||||
*
|
||||
* Code generated by Microsoft (R) AutoRest Code Generator.
|
||||
* Changes may cause incorrect behavior and will be lost if the code is regenerated.
|
||||
*/
|
||||
|
||||
import {
|
||||
env,
|
||||
record,
|
||||
RecorderEnvironmentSetup,
|
||||
Recorder
|
||||
} from "@azure-tools/test-recorder";
|
||||
import * as assert from "assert";
|
||||
|
||||
const recorderEnvSetup: RecorderEnvironmentSetup = {
|
||||
replaceableVariables: {
|
||||
AZURE_CLIENT_ID: "azure_client_id",
|
||||
AZURE_CLIENT_SECRET: "azure_client_secret",
|
||||
AZURE_TENANT_ID: "88888888-8888-8888-8888-888888888888",
|
||||
SUBSCRIPTION_ID: "azure_subscription_id"
|
||||
},
|
||||
customizationsOnRecordings: [
|
||||
(recording: any): any =>
|
||||
recording.replace(
|
||||
/"access_token":"[^"]*"/g,
|
||||
`"access_token":"access_token"`
|
||||
)
|
||||
],
|
||||
queryParametersToSkip: []
|
||||
};
|
||||
|
||||
describe("My test", () => {
|
||||
let recorder: Recorder;
|
||||
|
||||
beforeEach(async function() {
|
||||
recorder = record(this, recorderEnvSetup);
|
||||
});
|
||||
|
||||
afterEach(async function() {
|
||||
await recorder.stop();
|
||||
});
|
||||
|
||||
it("sample test", async function() {
|
||||
console.log("Hi, I'm a test!");
|
||||
});
|
||||
});
|
|
@ -0,0 +1,19 @@
|
|||
{
|
||||
"compilerOptions": {
|
||||
"module": "es6",
|
||||
"moduleResolution": "node",
|
||||
"strict": true,
|
||||
"target": "es6",
|
||||
"sourceMap": true,
|
||||
"declarationMap": true,
|
||||
"esModuleInterop": true,
|
||||
"allowSyntheticDefaultImports": true,
|
||||
"forceConsistentCasingInFileNames": true,
|
||||
"lib": ["es6", "dom"],
|
||||
"declaration": true,
|
||||
"outDir": "./dist-esm",
|
||||
"importHelpers": true
|
||||
},
|
||||
"include": ["./src/**/*.ts", "./test/**/*.ts"],
|
||||
"exclude": ["node_modules"]
|
||||
}
|
|
@ -0,0 +1,29 @@
|
|||
# NOTE: Please refer to https://aka.ms/azsdk/engsys/ci-yaml before editing this file.
|
||||
trigger:
|
||||
branches:
|
||||
include:
|
||||
- main
|
||||
- release/*
|
||||
- hotfix/*
|
||||
paths:
|
||||
include:
|
||||
- sdk/orbital/
|
||||
|
||||
pr:
|
||||
branches:
|
||||
include:
|
||||
- main
|
||||
- release/*
|
||||
- hotfix/*
|
||||
paths:
|
||||
include:
|
||||
- sdk/orbital/
|
||||
|
||||
extends:
|
||||
template: ../../eng/pipelines/templates/stages/archetype-sdk-client.yml
|
||||
parameters:
|
||||
ServiceDirectory: orbital
|
||||
Artifacts:
|
||||
- name: azure-arm-orbital
|
||||
safeName: azurearmorbital
|
||||
|
Загрузка…
Ссылка в новой задаче