Remove @param and @returns tags if they have no description (#12943)
Address feedback for https://github.com/Azure/azure-sdk-for-js/pull/12912.
This commit is contained in:
Родитель
cc5c4c8dda
Коммит
be0e8353f5
|
@ -141,7 +141,6 @@ export class AbortSignal implements AbortSignalLike {
|
|||
* - If there is a timeout, the timer will be cancelled.
|
||||
* - If aborted is true, nothing will happen.
|
||||
*
|
||||
* @returns
|
||||
* @internal
|
||||
*/
|
||||
// eslint-disable-next-line @azure/azure-sdk/ts-use-interface-parameters
|
||||
|
|
|
@ -19,8 +19,6 @@ export class AccessTokenRefresher {
|
|||
/**
|
||||
* Returns true if the required milliseconds(defaulted to 30000) have been passed signifying
|
||||
* that we are ready for a new refresh.
|
||||
*
|
||||
* @returns
|
||||
*/
|
||||
public isReady(): boolean {
|
||||
// We're only ready for a new refresh if the required milliseconds have passed.
|
||||
|
@ -34,7 +32,6 @@ export class AccessTokenRefresher {
|
|||
* then requests a new token,
|
||||
* then sets this.promise to undefined,
|
||||
* then returns the token.
|
||||
* @param options -
|
||||
*/
|
||||
private async getToken(options: GetTokenOptions): Promise<AccessToken | undefined> {
|
||||
this.lastCalled = Date.now();
|
||||
|
@ -46,7 +43,6 @@ export class AccessTokenRefresher {
|
|||
/**
|
||||
* Requests a new token if we're not currently waiting for a new token.
|
||||
* Returns null if the required time between each call hasn't been reached.
|
||||
* @param options -
|
||||
*/
|
||||
public refresh(options: GetTokenOptions): Promise<AccessToken | undefined> {
|
||||
if (!this.promise) {
|
||||
|
|
|
@ -74,7 +74,6 @@ export class BearerTokenAuthenticationPolicy extends BaseRequestPolicy {
|
|||
|
||||
/**
|
||||
* Applies the Bearer token to the request through the Authorization header.
|
||||
* @param webResource -
|
||||
*/
|
||||
public async sendRequest(webResource: WebResourceLike): Promise<HttpOperationResponse> {
|
||||
if (!webResource.headers) webResource.headers = new HttpHeaders();
|
||||
|
|
|
@ -27,9 +27,6 @@ export function ndJsonPolicy(): RequestPolicyFactory {
|
|||
class NdJsonPolicy extends BaseRequestPolicy {
|
||||
/**
|
||||
* Creates an instance of KeepAlivePolicy.
|
||||
*
|
||||
* @param nextPolicy -
|
||||
* @param options -
|
||||
*/
|
||||
constructor(nextPolicy: RequestPolicy, options: RequestPolicyOptions) {
|
||||
super(nextPolicy, options);
|
||||
|
@ -37,8 +34,6 @@ class NdJsonPolicy extends BaseRequestPolicy {
|
|||
|
||||
/**
|
||||
* Sends a request.
|
||||
*
|
||||
* @param request -
|
||||
*/
|
||||
public async sendRequest(request: WebResourceLike): Promise<HttpOperationResponse> {
|
||||
// There currently isn't a good way to bypass the serializer
|
||||
|
|
|
@ -6,16 +6,16 @@
|
|||
import * as msRest from "../../../../src/coreHttp";
|
||||
import { Mappers } from "./models/mappers";
|
||||
|
||||
/**
|
||||
* @param baseUri - The base URI of the service.
|
||||
* @param options - The parameter options
|
||||
*/
|
||||
|
||||
class TestClient extends msRest.ServiceClient {
|
||||
baseUri?: string;
|
||||
acceptLanguage?: string;
|
||||
models?: any;
|
||||
serializer: msRest.Serializer;
|
||||
|
||||
/**
|
||||
* @param baseUri - The base URI of the service.
|
||||
* @param options - The parameter options
|
||||
*/
|
||||
constructor(baseUri: string, options?: msRest.ServiceClientOptions) {
|
||||
if (!options) options = {};
|
||||
super(undefined, options);
|
||||
|
|
|
@ -383,7 +383,6 @@ export class EventHubReceiver extends LinkEntity {
|
|||
/**
|
||||
* Closes the underlying AMQP receiver.
|
||||
* @ignore
|
||||
* @returns
|
||||
*/
|
||||
async close(): Promise<void> {
|
||||
try {
|
||||
|
@ -542,7 +541,6 @@ export class EventHubReceiver extends LinkEntity {
|
|||
/**
|
||||
* Creates a new AMQP receiver under a new AMQP session.
|
||||
* @ignore
|
||||
* @returns
|
||||
*/
|
||||
async initialize(): Promise<void> {
|
||||
try {
|
||||
|
|
|
@ -543,7 +543,6 @@ export class EventHubSender extends LinkEntity {
|
|||
/**
|
||||
* Initializes the sender session on the connection.
|
||||
* @ignore
|
||||
* @returns
|
||||
*/
|
||||
private async _init(options: AwaitableSenderOptions): Promise<void> {
|
||||
try {
|
||||
|
@ -605,7 +604,6 @@ export class EventHubSender extends LinkEntity {
|
|||
* @ignore
|
||||
* @static
|
||||
* @param [partitionId] Partition ID to which it will send event data.
|
||||
* @returns
|
||||
*/
|
||||
static create(context: ConnectionContext, partitionId?: string): EventHubSender {
|
||||
const ehSender: EventHubSender = new EventHubSender(context, partitionId);
|
||||
|
|
|
@ -188,7 +188,6 @@ export class LinkEntity {
|
|||
/**
|
||||
* Ensures that the token is renewed within the predefined renewal margin.
|
||||
* @ignore
|
||||
* @returns
|
||||
*/
|
||||
protected async _ensureTokenRenewal(): Promise<void> {
|
||||
if (!this._tokenTimeoutInMs) {
|
||||
|
|
|
@ -288,7 +288,6 @@ export class ManagementClient extends LinkEntity {
|
|||
* Closes the AMQP management session to the Event Hub for this client,
|
||||
* returning a promise that will be resolved when disconnection is completed.
|
||||
* @ignore
|
||||
* @returns
|
||||
*/
|
||||
async close(): Promise<void> {
|
||||
try {
|
||||
|
|
|
@ -205,6 +205,7 @@ export class FormRecognizerClient {
|
|||
|
||||
/**
|
||||
* @internal
|
||||
* @hidden
|
||||
* A reference to the auto-generated FormRecognizer HTTP client.
|
||||
*/
|
||||
private readonly client: GeneratedClient;
|
||||
|
|
|
@ -7,7 +7,6 @@ import { CertificateContentType } from "./certificatesModels";
|
|||
/**
|
||||
* Decodes a Uint8Array into a Base64 string.
|
||||
* @internal
|
||||
* @param bytes -
|
||||
*/
|
||||
export function toBase64(bytes: Uint8Array): string {
|
||||
if (isNode) {
|
||||
|
@ -20,7 +19,6 @@ export function toBase64(bytes: Uint8Array): string {
|
|||
/**
|
||||
* Decodes a Uint8Array into an ASCII string.
|
||||
* @internal
|
||||
* @param bytes -
|
||||
*/
|
||||
export function toAscii(bytes: Uint8Array): string {
|
||||
if (isNode) {
|
||||
|
@ -33,7 +31,6 @@ export function toAscii(bytes: Uint8Array): string {
|
|||
/**
|
||||
* Encodes a JavaScript string into a Uint8Array.
|
||||
* @internal
|
||||
* @param value -
|
||||
*/
|
||||
export function stringToUint8Array(value: string): Uint8Array {
|
||||
if (isNode) {
|
||||
|
@ -46,7 +43,6 @@ export function stringToUint8Array(value: string): Uint8Array {
|
|||
/**
|
||||
* Encodes a Base64 string into a Uint8Array.
|
||||
* @internal
|
||||
* @param value -
|
||||
*/
|
||||
export function base64ToUint8Array(value: string): Uint8Array {
|
||||
if (isNode) {
|
||||
|
|
|
@ -117,7 +117,6 @@ export type SignAlgorithmName = "SHA256" | "SHA384" | "SHA512";
|
|||
* Since sign algorithms behave almost the same, we're making a generator to save up code.
|
||||
* We receive the sign algorithm, from the list of names in `SignAlgorithmName`,
|
||||
* then we generate a `LocalSupportedAlgorithm` that only create hashes and verifies signatures.
|
||||
* @param signAlgorithm -
|
||||
*/
|
||||
const makeSigner = (signAlgorithm: SignAlgorithmName): LocalSupportedAlgorithm => {
|
||||
return {
|
||||
|
|
|
@ -33,7 +33,6 @@ export async function generateKey(secret: string, stringToSign: string): Promise
|
|||
* @internal
|
||||
* @ignore
|
||||
* @param {string} value
|
||||
* @returns
|
||||
*/
|
||||
function convertToUint8Array(value: string) {
|
||||
const arr = new Uint8Array(value.length);
|
||||
|
|
|
@ -8,7 +8,6 @@
|
|||
* @internal
|
||||
* @ignore
|
||||
* @param {string} rawUrl
|
||||
* @returns
|
||||
*/
|
||||
export const parseURL = (rawUrl: string): any => {
|
||||
// eslint-disable-next-line @typescript-eslint/ban-ts-ignore
|
||||
|
|
|
@ -14,7 +14,6 @@ const url = require("url");
|
|||
* @internal
|
||||
* @ignore
|
||||
* @param {string} rawUrl
|
||||
* @returns
|
||||
*/
|
||||
export const parseURL = (rawUrl: string) => {
|
||||
return new url.URL(rawUrl);
|
||||
|
|
|
@ -24,7 +24,6 @@ import { logger } from "../log";
|
|||
*
|
||||
* @export
|
||||
* @param {StorageRetryOptions} retryOptions
|
||||
* @returns
|
||||
*/
|
||||
export function NewRetryPolicyFactory(retryOptions?: StorageRetryOptions): RequestPolicyFactory {
|
||||
return {
|
||||
|
|
|
@ -22,7 +22,6 @@ import { logger } from "../log";
|
|||
*
|
||||
* @export
|
||||
* @param {StorageRetryOptions} retryOptions
|
||||
* @returns
|
||||
*/
|
||||
export function NewRetryPolicyFactory(retryOptions?: StorageRetryOptions): RequestPolicyFactory {
|
||||
return {
|
||||
|
|
|
@ -18,7 +18,6 @@ export class ShareSASPermissions {
|
|||
*
|
||||
* @static
|
||||
* @param {string} permissions
|
||||
* @returns
|
||||
* @memberof ShareSASPermissions
|
||||
*/
|
||||
public static parse(permissions: string) {
|
||||
|
|
|
@ -24,7 +24,6 @@ import { logger } from "../log";
|
|||
*
|
||||
* @export
|
||||
* @param {StorageRetryOptions} retryOptions
|
||||
* @returns
|
||||
*/
|
||||
export function NewStorageRetryPolicyFactory(
|
||||
retryOptions?: StorageRetryOptions
|
||||
|
@ -273,7 +272,6 @@ export class StorageRetryPolicy extends BaseRequestPolicy {
|
|||
* @param {boolean} isPrimaryRetry
|
||||
* @param {number} attempt
|
||||
* @param {AbortSignalLike} [abortSignal]
|
||||
* @returns
|
||||
* @memberof StorageRetryPolicy
|
||||
*/
|
||||
private async delay(isPrimaryRetry: boolean, attempt: number, abortSignal?: AbortSignalLike) {
|
||||
|
|
|
@ -246,7 +246,6 @@ function parseBatchResponse(batchResponse: HttpOperationResponse): TableBatchRes
|
|||
/**
|
||||
* Prepares the operation url to be added to the body, removing the SAS token if present
|
||||
* @param url - Source URL string
|
||||
* @returns
|
||||
*/
|
||||
function getSubRequestUrl(url: string): string {
|
||||
const sasTokenParts = ["sv", "ss", "srt", "sp", "se", "st", "spr", "sig"];
|
||||
|
|
|
@ -4,8 +4,6 @@
|
|||
export class TablesSharedKeyCredential {
|
||||
/**
|
||||
* Creates an instance of TablesSharedKeyCredential.
|
||||
* @param accountName -
|
||||
* @param accountKey -
|
||||
*/
|
||||
constructor(_accountName: string, _accountKey: string) {
|
||||
throw new Error("TablesSharedKeyCredential is only supported in Node.js environment");
|
||||
|
|
|
@ -18,9 +18,6 @@ export interface TablesSharedKeyCredentialLike extends RequestPolicyFactory {
|
|||
accountName: string;
|
||||
/**
|
||||
* Generates a hash signature for an HTTP request or for a SAS.
|
||||
*
|
||||
* @param stringToSign -
|
||||
* @returns
|
||||
*/
|
||||
computeHMACSHA256: (stringToSign: string) => string;
|
||||
}
|
||||
|
@ -43,8 +40,6 @@ export class TablesSharedKeyCredential implements TablesSharedKeyCredentialLike
|
|||
|
||||
/**
|
||||
* Creates an instance of TablesSharedKeyCredential.
|
||||
* @param accountName -
|
||||
* @param accountKey -
|
||||
*/
|
||||
constructor(accountName: string, accountKey: string) {
|
||||
this.accountName = accountName;
|
||||
|
@ -53,10 +48,6 @@ export class TablesSharedKeyCredential implements TablesSharedKeyCredentialLike
|
|||
|
||||
/**
|
||||
* Creates a {@link TablesSharedKeyCredentialPolicy} object.
|
||||
*
|
||||
* @param nextPolicy -
|
||||
* @param options -
|
||||
* @returns
|
||||
*/
|
||||
public create(
|
||||
nextPolicy: RequestPolicy,
|
||||
|
@ -67,9 +58,6 @@ export class TablesSharedKeyCredential implements TablesSharedKeyCredentialLike
|
|||
|
||||
/**
|
||||
* Generates a hash signature for an HTTP request or for a SAS.
|
||||
*
|
||||
* @param stringToSign -
|
||||
* @returns
|
||||
*/
|
||||
public computeHMACSHA256(stringToSign: string): string {
|
||||
return createHmac("sha256", this.accountKey)
|
||||
|
|
|
@ -24,9 +24,6 @@ export class TablesSharedKeyCredentialPolicy extends BaseRequestPolicy {
|
|||
|
||||
/**
|
||||
* Creates an instance of TablesSharedKeyCredentialPolicy.
|
||||
* @param nextPolicy -
|
||||
* @param options -
|
||||
* @param factory -
|
||||
*/
|
||||
constructor(
|
||||
nextPolicy: RequestPolicy,
|
||||
|
@ -39,9 +36,6 @@ export class TablesSharedKeyCredentialPolicy extends BaseRequestPolicy {
|
|||
|
||||
/**
|
||||
* Sends out request.
|
||||
*
|
||||
* @param request -
|
||||
* @returns
|
||||
*/
|
||||
public sendRequest(request: WebResourceLike): Promise<HttpOperationResponse> {
|
||||
return this._nextPolicy.sendRequest(this.signRequest(request));
|
||||
|
@ -49,9 +43,6 @@ export class TablesSharedKeyCredentialPolicy extends BaseRequestPolicy {
|
|||
|
||||
/**
|
||||
* Signs request.
|
||||
*
|
||||
* @param request -
|
||||
* @returns
|
||||
*/
|
||||
public signRequest(request: WebResourceLike): WebResource {
|
||||
const headerValue = getAuthorizationHeader(request, this.credential);
|
||||
|
|
|
@ -15,7 +15,6 @@ import { URL } from "./url";
|
|||
* - SAS Connection String: Attach a SAS token to the storage account url for authentication
|
||||
* @param connectionString - Connection string to parse
|
||||
* @param options - TableService client options
|
||||
* @returns
|
||||
*/
|
||||
export function getClientParamsFromConnectionString(
|
||||
connectionString: string,
|
||||
|
|
|
@ -66,7 +66,6 @@ export abstract class BaseRecorder {
|
|||
*
|
||||
* @protected
|
||||
* @param content
|
||||
* @returns
|
||||
* @memberof BaseRecorder
|
||||
*/
|
||||
protected filterSecrets(content: any): any {
|
||||
|
|
|
@ -20,7 +20,6 @@ import fs from "fs-extra";
|
|||
* path: string;
|
||||
* content: string;
|
||||
* }} browserRecordingJsonObject
|
||||
* @returns
|
||||
*/
|
||||
export const jsonRecordingFilterFunction = function(browserRecordingJsonObject: {
|
||||
writeFile: boolean;
|
||||
|
|
|
@ -170,7 +170,6 @@ export function applyReplacementFunctions(
|
|||
* @param {string} content
|
||||
* @param { [ENV_VAR: string]: string } replaceableVariables
|
||||
* @param {ReplacementFunctions} replacements
|
||||
* @returns
|
||||
*/
|
||||
export function filterSecretsFromStrings(
|
||||
content: string,
|
||||
|
@ -190,7 +189,6 @@ export function filterSecretsFromStrings(
|
|||
* @param {any} content
|
||||
* @param { [ENV_VAR: string]: string } replaceableVariables
|
||||
* @param {ReplacementFunctions} replacements
|
||||
* @returns
|
||||
*/
|
||||
export function filterSecretsRecursivelyFromJSON(
|
||||
content: any,
|
||||
|
|
Загрузка…
Ссылка в новой задаче