UNPKG

appcenter-cli

Version:

Command line tool for Visual Studio App Center

1,886 lines (1,675 loc) 578 kB
// Generated by typings // Source: https://raw.githubusercontent.com/typed-contrib/azure-storage-node/140f44b051ee914e350e3d777cb8a096ec9a2b94/lib/common/diagnostics/logger.d.ts declare module '~azure-storage/lib/common/diagnostics/logger' { // Type definitions for azure-storage-node v0.10.0 // Project: https://github.com/Azure/azure-storage-node // Definitions by: Maxime LUCE <https://github.com/SomaticIT/> // Definitions: https://github.com/typed-contrib/azure-storage-node /** * @class * The Logger class is used to write log information. */ class Logger { /** * The log level. Refer to the Logger.LogLevels for available log levels. * @name Logger#level * @type {string} * @see Logger.LogLevels */ level: string; /** * @constructor * Creates a new Logger object * @param {string} [level] The log level. Refer to Logger.LogLevels. * @param {object} [loggerFunction] The function to write log information. */ constructor(level?: string, loggerFunction?: (level: string, msg: string) => void); log(level: string, msg: string): void; emergency(msg: string): void; critical(msg: string): void; alert(msg: string): void; error(msg: string): void; warn(msg: string): void; notice(msg: string): void; info(msg: string): void; debug(msg: string): void; /** * The available log levels. * * @const * @enum {string} */ static LogLevels: { /** * System is unusable. */ EMERGENCY: 'emergency', /** * Action must be taken immediately. */ ALERT : 'alert', /** * Critical condition. */ CRITICAL : 'critical', /** * Error condition. */ ERROR : 'error', /** * Warning condition. */ WARNING : 'warning', /** * Normal but significant condition. */ NOTICE : 'notice', /** * Purely informational message. */ INFO : 'info', /** * Application debug messages. */ DEBUG : 'debug' }; } export = Logger; } declare module 'azure-storage/lib/common/diagnostics/logger' { import main = require('~azure-storage/lib/common/diagnostics/logger'); export = main; } // Generated by typings // Source: https://raw.githubusercontent.com/typed-contrib/azure-storage-node/140f44b051ee914e350e3d777cb8a096ec9a2b94/lib/common/http/webresource.d.ts declare module '~azure-storage/lib/common/http/webresource' { // Type definitions for azure-storage-node v0.10.0 // Project: https://github.com/Azure/azure-storage-node // Definitions by: Maxime LUCE <https://github.com/SomaticIT/> // Definitions: https://github.com/typed-contrib/azure-storage-node type Map<T> = { [key: string]: T }; /** * This class provides an abstraction over a REST call by being library / implementation agnostic and wrapping the necessary * properties to initiate a request. */ class WebResource { rawResponse: boolean; headersOnly: boolean; queryString: Map<any>; properties: Map<string>; headers: Map<any>; body: any; /** * @constructor * Creates a new WebResource object. */ constructor(); /** * Creates a new put request web resource. * * @param {string} [path] The path for the put operation. * @return {WebResource} A new webresource with a put operation for the given path. */ static put(path?: string): WebResource; /** * Creates a new get request web resource. * * @param {string} [path] The path for the get operation. * @return {WebResource} A new webresource with a get operation for the given path. */ static get(path?: string): WebResource; /** * Creates a new head request web resource. * * @param {string} [path] The path for the head operation. * @return {WebResource} A new webresource with a head operation for the given path. */ static head(path?: string): WebResource; /** * Creates a new del request web resource. * * @param {string} [path] The path for the del operation. * @return {WebResource} A new webresource with a del operation for the given path. */ static del(path?: string): WebResource; /** * Creates a new post request web resource. * * @param {string} [path] The path for the post operation. * @return {WebResource} A new webresource with a post operation for the given path. */ static post(path?: string): WebResource; /** * Creates a new merge request web resource. * * @param {string} [path] The path for the merge operation. * @return {WebResource} A new webresource with a merge operation for the given path. */ static merge(path?: string): WebResource; /** * Specifies a custom property in the web resource. * * @param {string} name The property name. * @param {string} value The property value. * @return {WebResource} The webresource. */ withProperty(name: string, value: string): this; /** * Specifies that the response should not be parsed. * @return {WebResource} The webresource. */ withRawResponse(): this; /** * Specifies if the response should be parsed or not. * * @param {bool} rawResponse true if the response should not be parsed; false otherwise. * @return {WebResource} The webresource. */ withRawResponse(rawResponse?: boolean): this; /** * Specifies that the response should contains only headers. * @return {WebResource} The webresource. */ withHeadersOnly(): this; /** * Specifies if the response should be contains only headers or not. * * @param {bool} headersOnly true if the response should contains only headers; false otherwise. * @return {WebResource} The webresource. */ withHeadersOnly(headersOnly?: boolean): this; /** * Adds an optional query string parameter. * * @param {Object} name The name of the query string parameter. * @param {Object} value The value of the query string parameter. * @param {Object} [defaultValue]The default value for the query string parameter to be used if no value is passed. * @return {WebResource} The web resource. */ withQueryOption(name: string, value: any, defaultValue?: any): this; /** * Adds optional query string parameters. * Additional arguments will be the needles to search in the haystack. * * @param {Object} object The haystack of query string parameters. * @return {WebResource} The web resource. */ withQueryOptions(options: Map<any>, ...properties: string[]): this; /** * Adds an optional header parameter. * * @param {Object} name The name of the header parameter. * @param {Object} value The value of the header parameter. * @return {WebResource} The web resource. */ withHeader(name: string, value: any): this; /** * Adds optional header parameters. * * Additional arguments will be the needles to search in the haystack. * * @param {Object} object The haystack of headers. * @return {Object} The web resource. */ withHeaders(options: Map<any>, ...properties: string[]): this; /** * Adds an optional body. * * @param {Object} body The request body. * @return {WebResource} The web resource. */ withBody(body: any): this; addOptionalMetadataHeaders(metadata: Map<any>): this; static validResponse(statusCode: number): boolean; /** * Hook up the given input stream to a destination output stream if the WebResource method * requires a request body and a body is not already set. * * @param {Stream} inputStream the stream to pipe from * @param {Stream} outputStream the stream to pipe to * * @return destStream */ pipeInput(inputStream: NodeJS.ReadableStream, outputStream: NodeJS.WritableStream): typeof outputStream; } export = WebResource; } declare module 'azure-storage/lib/common/http/webresource' { import main = require('~azure-storage/lib/common/http/webresource'); export = main; } // Generated by typings // Source: https://raw.githubusercontent.com/typed-contrib/azure-storage-node/140f44b051ee914e350e3d777cb8a096ec9a2b94/lib/common/services/storageserviceclient.d.ts declare module '~azure-storage/lib/common/services/storageserviceclient' { // Type definitions for azure-storage-node v0.10.0 // Project: https://github.com/Azure/azure-storage-node // Definitions by: Maxime LUCE <https://github.com/SomaticIT/> // Definitions: https://github.com/typed-contrib/azure-storage-node import * as events from 'events'; import Logger = require('~azure-storage/lib/common/diagnostics/logger'); import WebResource = require('~azure-storage/lib/common/http/webresource'); import RetryPolicyFilter = require('~azure-storage/lib/common/filters/retrypolicyfilter'); import { date } from '~azure-storage/lib/common/util/date'; import { AccessConditions } from '~azure-storage/lib/common/util/accesscondition'; import { StorageError } from '~azure-storage/lib/common/errors/errors'; /** * @class * The StorageServiceClient class is the base class of all the service classes. */ class StorageServiceClient extends events.EventEmitter { storageAccount: string; storageAccessKey: string; sasToken: string; anonymous: boolean; storageCredentials: StorageServiceClient.IRequestSigner; apiVersion: string; usePathStyleUri: boolean; xml2jsSettings: any; defaultLocationMode: number; logger: Logger; host: StorageServiceClient.Host; /** * @constructor * Creates a new StorageServiceClient object. * * @param {string} [storageAccount] The storage account. * @param {string} [storageAccessKey] The storage access key. * @param {object} [host] The host for the service. * @param {bool} [usePathStyleUri] Boolean value indicating wether to use path style uris. * @param {string} [sasToken] The Shared Access Signature token. */ constructor(storageAccount?: string, storageAccessKey?: string, host?: StorageServiceClient.Host, usePathStyleUri?: boolean, sasToken?: string); /** * Associate a filtering operation with this StorageServiceClient. Filtering operations * can include logging, automatically retrying, etc. Filter operations are objects * that implement a method with the signature: * * "function handle (requestOptions, next)". * * After doing its preprocessing on the request options, the method needs to call * "next" passing a callback with the following signature: * signature: * * "function (returnObject, finalCallback, next)" * * In this callback, and after processing the returnObject (the response from the * request to the server), the callback needs to either invoke next if it exists to * continue processing other filters or simply invoke finalCallback otherwise to end * up the service invocation. * * @param {Object} filter The new filter object. * @return {StorageServiceClient} A new service client with the filter applied. */ withFilter(newFilter: RetryPolicyFilter.IRetryFilter): this; /** * Sets a host for the service. * @param {object} host The host for the service. */ setHost(host: StorageServiceClient.Host): void; /** * Gets the storage settings. * * @param {string} [storageAccountOrConnectionString] The storage account or the connection string. * @param {string} [storageAccessKey] The storage access key. * @param {string} [host] The host address. * @param {object} [sasToken] The sas token. * * @return {StorageServiceSettings} */ getStorageSettings(storageAccountOrConnectionString?: string, storageAccessKey?: string, host?: StorageServiceClient.HostConfiguration, sasToken?: string): StorageServiceClient.StorageServiceSettings; /** * Gets the properties of a storage account’s service, including Azure Storage Analytics. * @param {errorOrResult} callback `error` will contain information if an error occurs; otherwise, `result` will contain the properties * and `response` will contain information related to this operation. */ getAccountServiceProperties(callback: StorageServiceClient.ErrorOrResult<StorageServiceClient.ServiceProperties>): void; /** * Gets the properties of a storage account’s service, including Azure Storage Analytics. * @param {object} options The request options. * @param {errorOrResult} callback `error` will contain information if an error occurs; otherwise, `result` will contain the properties * and `response` will contain information related to this operation. */ getAccountServiceProperties(options: StorageServiceClient.ServiceOptions, callback: StorageServiceClient.ErrorOrResult<StorageServiceClient.ServiceProperties>): void; /** * Sets the properties of a storage account’s service, including Azure Storage Analytics. * You can also use this operation to set the default request version for all incoming requests that do not have a version specified. * * @this {StorageServiceClient} * @param {ServiceProperties} serviceProperties The service properties. * @param {ServiceOptions} options The request options. * @param {errorOrResponse} callback `error` will contain information * if an error occurs; otherwise, `response` * will contain information related to this operation. */ setAccountServiceProperties(serviceProperties: StorageServiceClient.ServiceProperties, callback: StorageServiceClient.ErrorOrResponse): void; /** * Sets the properties of a storage account’s service, including Azure Storage Analytics. * You can also use this operation to set the default request version for all incoming requests that do not have a version specified. * * @this {StorageServiceClient} * @param {ServiceProperties} serviceProperties The service properties. * @param {errorOrResponse} callback `error` will contain information * if an error occurs; otherwise, `response` * will contain information related to this operation. */ setAccountServiceProperties(serviceProperties: StorageServiceClient.ServiceProperties, options: StorageServiceClient.ServiceOptions, callback: StorageServiceClient.ErrorOrResponse): void; } namespace StorageServiceClient { export type HostConfiguration = string | Host; export type ErrorOrResponse = (err: StorageError, response: ServiceResponse) => void; export type ErrorOrResult<T> = (err: StorageError, result: T, response: ServiceResponse) => void; export type ErrorOrList<T> = (err: StorageError, result: List<T>, response: ServiceResponse) => void; export interface List<T> { entries: T[]; continuationToken: ContinuationToken; } export interface Host { primaryHost?: string; secondaryHost?: string; } export interface IRequestSigner { signRequest(webResource: WebResource, callback: (err: Error) => void): void; } export interface StorageServiceSettings { _name: string; _key: string; _sasToken: string; _blobEndpoint: string; _queueEndpoint: string; _tableEndpoint: string; _fileEndpoint: string; _usePathStyleUri: boolean; } export interface ServiceProperties { Logging?: ServiceLogging; HourMetrics?: ServiceMetrics; MinuteMetrics?: ServiceMetrics; Cors?: ServiceCorsRule[]; /** The DefaultServiceVersion element can only be set for the Blob service and the request must be made using version 2011-08-18 or later. */ DefaultServiceVersion?: string; } export interface ServiceLogging { Version: string; Delete: boolean; Read: boolean; Write: boolean; RetentionPolicy: ServiceRetentionPolicy; } export interface ServiceMetrics { Version: string; Enabled: boolean; IncludeAPIs?: boolean; RetentionPolicy: ServiceRetentionPolicy; } export interface ServiceRetentionPolicy { Enabled: boolean; Days?: number; } export interface ServiceCorsRule { CorsRule: { AllowedOrigins: string[]; AllowedMethods: string[]; AllowedHeaders: string[]; ExposedHeaders: string[]; MaxAgeInSeconds: number; }; } export interface ServiceStats { GeoReplication?: { Status?: string; LastSyncTime?: Date; }; } export interface ServiceOptions { /** * Specifies the location mode used to decide which location the request should be sent to. * Please see StorageUtilities.LocationMode for the possible values. */ locationMode?: number; /** The server timeout interval, in milliseconds, to use for the request. */ timeoutIntervalInMs?: number; /** * The maximum execution time, in milliseconds, across all potential retries, to use when making this request. * The maximum execution time interval begins at the time that the client begins building the request. The maximum * execution time is checked intermittently while performing requests, and before executing retries. */ maximumExecutionTimeInMs?: number; /** * Determines whether the Nagle algorithm is used; true to use the Nagle algorithm; otherwise, false. * The default value is false. */ useNagleAlgorithm?: boolean; } export interface AccessConditionsOptions extends ServiceClientOptions { accessConditions?: AccessConditions; } export interface ServiceClientOptions extends ServiceOptions { /** A string that represents the client request ID with a 1KB character limit. */ clientRequestId?: string; } export interface ServiceResponse { /** Boolean value indicating if the request was successful. */ isSuccessful: boolean; /** The response body. */ body: any; /** The response headers. */ headers: any; /** The response status code. */ statusCode: number; /** The response's content md5 hash. */ md5: string; } export interface SignedIdentifiers { [key: string]: AccessPolicy; } export interface SharedAccessPolicy { /** The signed identifier. */ Id?: string; /** The Access Policy information. */ AccessPolicy?: AccessPolicy; } export interface AccessPolicy { /** The permission type. */ Permissions?: string; /** The time at which the Shared Access Signature becomes valid (The UTC value will be used). */ Start?: date; /** The time at which the Shared Access Signature becomes expired (The UTC value will be used). */ Expiry?: date; /** An IP address or a range of IP addresses from which to accept requests. When specifying a range, note that the range is inclusive. */ IPAddressOrRange?: string; /** * The protocol permitted for a request made with the account SAS. * Possible values are both HTTPS and HTTP (https,http) or HTTPS only (https). * The default value is https,http. */ Protocols?: string; } export interface SignedIdentifiersResult { [key: string]: AccessPolicyResult; } export interface AccessPolicyResult { /** The permission type. */ Permissions?: string; /** The time at which the Shared Access Signature becomes valid (The UTC value will be used). */ Start?: Date; /** The time at which the Shared Access Signature becomes expired (The UTC value will be used). */ Expiry?: Date; /** An IP address or a range of IP addresses from which to accept requests. When specifying a range, note that the range is inclusive. */ IPAddressOrRange?: string; /** * The protocol permitted for a request made with the account SAS. * Possible values are both HTTPS and HTTP (https,http) or HTTPS only (https). * The default value is https,http. */ Protocols?: string; } export interface ContinuationToken { } } export = StorageServiceClient; } declare module 'azure-storage/lib/common/services/storageserviceclient' { import main = require('~azure-storage/lib/common/services/storageserviceclient'); export = main; } // Generated by typings // Source: https://raw.githubusercontent.com/typed-contrib/azure-storage-node/140f44b051ee914e350e3d777cb8a096ec9a2b94/lib/common/filters/linearretrypolicyfilter.d.ts declare module '~azure-storage/lib/common/filters/linearretrypolicyfilter' { // Type definitions for azure-storage-node v0.10.0 // Project: https://github.com/Azure/azure-storage-node // Definitions by: Maxime LUCE <https://github.com/SomaticIT/> // Definitions: https://github.com/typed-contrib/azure-storage-node import * as RetryPolicyFilter from '~azure-storage/lib/common/filters/retrypolicyfilter'; /** * @class * The LinearRetryPolicyFilter allows you to retry operations, * using an linear back-off interval between retries. * To apply a filter to service operations, use `withFilter` * and specify the filter to be used when creating a service. */ class LinearRetryPolicyFilter implements RetryPolicyFilter.IRetryFilter { retryCount: number; retryInterval: number; /** * @constructor * @param {number} [retryCount=3] The client retry count. * @param {number} [retryInterval=30000] The client retry interval, in milliseconds. */ constructor(retryCount?: number, retryInterval?: number); /** * Represents the default client retry interval, in milliseconds. */ static DEFAULT_CLIENT_RETRY_INTERVAL: number; /** * Represents the default client retry count. */ static DEFAULT_CLIENT_RETRY_COUNT: number; handle(requestOptions: any, next: RetryPolicyFilter.HandleCallback): void; shouldRetry(statusCode: number, requestOptions: any): RetryPolicyFilter.RetryInfo; } export = LinearRetryPolicyFilter; } declare module 'azure-storage/lib/common/filters/linearretrypolicyfilter' { import main = require('~azure-storage/lib/common/filters/linearretrypolicyfilter'); export = main; } // Generated by typings // Source: https://raw.githubusercontent.com/typed-contrib/azure-storage-node/140f44b051ee914e350e3d777cb8a096ec9a2b94/lib/common/filters/exponentialretrypolicyfilter.d.ts declare module '~azure-storage/lib/common/filters/exponentialretrypolicyfilter' { // Type definitions for azure-storage-node v0.10.0 // Project: https://github.com/Azure/azure-storage-node // Definitions by: Maxime LUCE <https://github.com/SomaticIT/> // Definitions: https://github.com/typed-contrib/azure-storage-node import * as RetryPolicyFilter from '~azure-storage/lib/common/filters/retrypolicyfilter'; /** * @class * The ExponentialRetryPolicyFilter allows you to retry operations, * using an exponential back-off interval between retries. * To apply a filter to service operations, use `withFilter` * and specify the filter to be used when creating a service. */ class ExponentialRetryPolicyFilter implements RetryPolicyFilter.IRetryFilter { retryCount: number; retryInterval: number; minRetryInterval: number; maxRetryInterval: number; /** * @constructor * @param {number} [retryCount=3] The client retry count. * @param {number} [retryInterval=30000] The client retry interval, in milliseconds. * @param {number} [minRetryInterval=3000] The minimum retry interval, in milliseconds. * @param {number} [maxRetryInterval=90000] The maximum retry interval, in milliseconds. */ constructor(retryCount?: number, retryInterval?: number, minRetryInterval?: number, maxRetryInterval?: number); /** * Represents the default client retry interval, in milliseconds. */ static DEFAULT_CLIENT_RETRY_INTERVAL: number; /** * Represents the default client retry count. */ static DEFAULT_CLIENT_RETRY_COUNT: number; /** * Represents the default maximum retry interval, in milliseconds. */ static DEFAULT_CLIENT_MAX_RETRY_INTERVAL: number; /** * Represents the default minimum retry interval, in milliseconds. */ static DEFAULT_CLIENT_MIN_RETRY_INTERVAL: number; handle(requestOptions: any, next: RetryPolicyFilter.HandleCallback): void; shouldRetry(statusCode: number, requestOptions: any): RetryPolicyFilter.RetryInfo; } export = ExponentialRetryPolicyFilter; } declare module 'azure-storage/lib/common/filters/exponentialretrypolicyfilter' { import main = require('~azure-storage/lib/common/filters/exponentialretrypolicyfilter'); export = main; } // Generated by typings // Source: https://raw.githubusercontent.com/typed-contrib/azure-storage-node/140f44b051ee914e350e3d777cb8a096ec9a2b94/lib/common/filters/retrypolicyfilter.d.ts declare module '~azure-storage/lib/common/filters/retrypolicyfilter' { // Type definitions for azure-storage-node v0.10.0 // Project: https://github.com/Azure/azure-storage-node // Definitions by: Maxime LUCE <https://github.com/SomaticIT/> // Definitions: https://github.com/typed-contrib/azure-storage-node /** * @class * The RetryPolicyFilter allows you to retry operations, * using a custom retry policy. Users are responsible to * define the shouldRetry method. * To apply a filter to service operations, use `withFilter` * and specify the filter to be used when creating a service. */ class RetryPolicyFilter implements RetryPolicyFilter.IRetryFilter { retryCount: number; retryInterval: number; /** * @constructor * @param {number} [retryCount=30000] The client retry count. * @param {number} [retryInterval=3] The client retry interval, in milliseconds. */ constructor(retryCount?: number, retryInterval?: number); /** * Represents the default client retry interval, in milliseconds. */ static DEFAULT_CLIENT_RETRY_INTERVAL: number; /** * Represents the default client retry count. */ static DEFAULT_CLIENT_RETRY_COUNT: number; /** * Handles an operation with a retry policy. * * @param {Object} requestOptions The original request options. * @param {function} next The next filter to be handled. */ handle(requestOptions: any, next: RetryPolicyFilter.HandleCallback): void; /** * Implements a should-retry policy. TO BE IMPLEMENTED! * @abstract * @param {number} statusCode The request status code. * @param {Object} requestOptions The original request options. */ /*abstract*/ shouldRetry(statusCode: number, requestOptions: any): RetryPolicyFilter.RetryInfo; /** * Handles an operation with a retry policy. * * @param {Object} requestOptions The original request options. * @param {function} next The next filter to be handled. */ static _handle(self: RetryPolicyFilter, requestOptions: any, next: RetryPolicyFilter.HandleCallback): void; static __shouldRetryOnError(statusCode: number, requestOptions: any): RetryPolicyFilter.RetryInfo; } namespace RetryPolicyFilter { export interface IRetryFilter { retryCount?: number; retryInterval?: number; handle(requestOptions: any, next: HandleCallback): void; shouldRetry(statusCode: number, requestOptions: any): RetryInfo; } export interface ReturnObject { error?: Error; retryable?: boolean; response?: any; } export interface RetryInfo { retryCount?: number; retryInterval?: number; locationMode?: string; currentLocation?: string; error?: Error; lastServerError?: boolean; ignore?: boolean; retryable?: boolean; } export interface NextCallback { (returnObject: ReturnObject): void; } export interface HandleCallback { (returnObject: ReturnObject, finalCallback: NextCallback, next: NextCallback): void; } } export = RetryPolicyFilter; } declare module 'azure-storage/lib/common/filters/retrypolicyfilter' { import main = require('~azure-storage/lib/common/filters/retrypolicyfilter'); export = main; } // Generated by typings // Source: https://raw.githubusercontent.com/typed-contrib/azure-storage-node/140f44b051ee914e350e3d777cb8a096ec9a2b94/lib/common/streams/speedsummary.d.ts declare module '~azure-storage/lib/common/streams/speedsummary' { // Type definitions for azure-storage-node v0.10.0 // Project: https://github.com/Azure/azure-storage-node // Definitions by: Maxime LUCE <https://github.com/SomaticIT/> // Definitions: https://github.com/typed-contrib/azure-storage-node /** * Blob upload/download speed summary */ class SpeedSummary { name: string; _startTime: Date; _timeWindowInSeconds: number; _timeWindow: number; _totalWindowSize: number; _speedTracks: any[]; _speedTrackPtr: number; totalSize: number; completeSize: number; constructor(name?: string); /** Get running seconds. */ getElapsedSeconds(): number; /** Get running seconds. */ getElapsedSeconds(humanReadable: boolean): number | string; /** * Get complete percentage. * @param {int} len The number of digits after the decimal point. */ getCompletePercent(len?: number): number; /** Get average upload/download speed. */ getAverageSpeed(): number; /** Get average upload/download speed. */ getAverageSpeed(humanReadable: boolean): number | string; /** Get instant upload/download speed. */ getSpeed(): number; /** Get instant upload/download speed. */ getSpeed(humanReadable: boolean): number | string; /** Increment the complete data size. */ increment(len: number): number; /** Get auto increment function. */ getAutoIncrementFunction(size: number): (err: Error, result: any) => void; /** Get total size. */ getTotalSize(): number; /** Get total size. */ getTotalSize(humanReadable: boolean): number | string; /** Get completed data size. */ getCompleteSize(): number; /** Get completed data size. */ getCompleteSize(humanReadable: boolean): number | string; } export = SpeedSummary; } declare module 'azure-storage/lib/common/streams/speedsummary' { import main = require('~azure-storage/lib/common/streams/speedsummary'); export = main; } // Generated by typings // Source: https://raw.githubusercontent.com/typed-contrib/azure-storage-node/140f44b051ee914e350e3d777cb8a096ec9a2b94/lib/common/util/constants.d.ts declare module '~azure-storage/lib/common/util/constants' { // Type definitions for azure-storage-node v0.10.0 // Project: https://github.com/Azure/azure-storage-node // Definitions by: Maxime LUCE <https://github.com/SomaticIT/> // Definitions: https://github.com/typed-contrib/azure-storage-node /* * Specifies the value to use for UserAgent header. * @const * @default "Azure-Storage" */ export const USER_AGENT_PRODUCT_NAME: string; /* * Specifies the value to use for UserAgent header. * @const * @default "0.10.0" */ export const USER_AGENT_PRODUCT_VERSION: string; /** * The number of default concurrent requests for parallel operation. * * @const * @type {string} */ export const DEFAULT_PARALLEL_OPERATION_THREAD_COUNT: number; /** * Constant representing a kilobyte (Non-SI version). * * @const * @type {string} */ export const KB: number; /** * Constant representing a megabyte (Non-SI version). * * @const * @type {string} */ export const MB: number; /** * Constant representing a gigabyte (Non-SI version). * * @const * @type {string} */ export const GB: number; /** * Specifies HTTP. * * @const * @type {string} * @default "http" */ export const HTTP: string; /** * Specifies HTTPS. * * @const * @type {string} * @default "https" */ export const HTTPS: string; /** * Default HTTP port. * * @const * @type {int} */ export const DEFAULT_HTTP_PORT: number; /** * Default HTTPS port. * * @const * @type {int} */ export const DEFAULT_HTTPS_PORT: number; /** * Marker for atom metadata. * * @const * @type {string} * @default "$" */ export const XML_METADATA_MARKER: string; /** * Marker for atom value. * * @const * @type {string} * @default "_" */ export const XML_VALUE_MARKER: string; /** * Defines the service types indicators. * * @const * @enum */ export const ServiceType: { /** * @const * @default "blob" */ Blob: string; /** * @const * @default "queue" */ Queue: string; /** * @const * @default "table" */ Table: string; /** * @const * @default "file" */ File: string; }; /** * Specifies the location used to indicate which location the operation can be performed against. * * @const * @enum */ export const RequestLocationMode: { PRIMARY_ONLY: number; SECONDARY_ONLY: number; PRIMARY_OR_SECONDARY: number; }; /** * Represents a storage service location. * * @const * @enum */ export const StorageLocation: { PRIMARY: number; SECONDARY: number; }; export const AccountSasConstants: { /** * Permission types * * @const * @enum {string} */ Permissions: { /** * @const * @default "r" */ READ: string; /** * @const * @default "a" */ ADD: string; /** * @const * @default "c" */ CREATE: string; /** * @const * @default "u" */ UPDATE: string; /** * @const * @default "p" */ PROCESS: string; /** * @const * @default "w" */ WRITE: string; /** * @const * @default "d" */ DELETE: string; /** * @const * @default "l" */ LIST: string; }; /** * Services types * * @const * @enum {string} */ Services: { /** * @const * @default "b" */ BLOB: string; /** * @const * @default "f" */ FILE: string; /** * @const * @default "q" */ QUEUE: string; /** * @const * @default "t" */ TABLE: string; }; /** * Resources types * * @const * @enum {string} */ Resources: { /** * @const * @default "s" */ SERVICE: string; /** * @const * @default "c" */ CONTAINER: string; /** * @const * @default "o" */ OBJECT: string; }; Protocols: { /** * @const * @default "https" */ HTTPSONLY: string; /** * @const * @default "https;http" */ HTTPSORHTTP: string; }; }; /** * Defines constants for use with shared access policies. */ export const AclConstants: { /** * XML element for an access policy. * * @const * @type {string} * @default "AccessPolicy" */ ACCESS_POLICY: string; /** * XML element for the end time of an access policy. * * @const * @type {string} * @default "Expiry" */ EXPIRY: string; /** * XML attribute for IDs. * * @const * @type {string} * @default "Id" */ ID: string; /** * XML element for the permission of an access policy. * * @const * @type {string} * @default "Permission" */ PERMISSION: string; /** * XML element for a signed identifier. * * @const * @type {string} * @default "SignedIdentifier" */ SIGNED_IDENTIFIER_ELEMENT: string; /** * XML element for signed identifiers. * * @const * @type {string} * @default "SignedIdentifiers" */ SIGNED_IDENTIFIERS_ELEMENT: string; /** * XML element for the start time of an access policy. * * @const * @type {string} * @default "Start" */ START: string; }; /** * Defines constants for use with service properties. */ export const ServicePropertiesConstants: { /** * XML element for storage service properties. * * @const * @type {string} * @default "StorageServiceProperties" */ STORAGE_SERVICE_PROPERTIES_ELEMENT: string; /** * Default analytics version to send for logging; hour metrics and minute metrics. * * @const * @type {string} * @default "1.0" */ DEFAULT_ANALYTICS_VERSION: string; /** * XML element for logging. * * @const * @type {string} * @default "Logging" */ LOGGING_ELEMENT: string; /** * XML element for version. * * @const * @type {string} * @default "Version" */ VERSION_ELEMENT: string; /** * XML element for delete. * * @const * @type {string} * @default "Delete" */ DELETE_ELEMENT: string; /** * XML element for read. * * @const * @type {string} * @default "Read" */ READ_ELEMENT: string; /** * XML element for write. * * @const * @type {string} * @default "Write" */ WRITE_ELEMENT: string; /** * XML element for retention policy. * * @const * @type {string} * @default "RetentionPolicy" */ RETENTION_POLICY_ELEMENT: string; /** * XML element for enabled. * * @const * @type {string} * @default "Enabled" */ ENABLED_ELEMENT: string; /** * XML element for days. * * @const * @type {string} * @default "Days" */ DAYS_ELEMENT: string; /** * XML element for HourMetrics. * * @const * @type {string} * @default "HourMetrics" */ HOUR_METRICS_ELEMENT: string; /** * XML element for MinuteMetrics. * * @const * @type {string} * @default "MinuteMetrics" */ MINUTE_METRICS_ELEMENT: string; /** * XML element for Cors. * * @const * @type {string} * @default "Cors" */ CORS_ELEMENT: string; /** * XML element for CorsRule. * * @const * @type {string} * @default "CorsRule" */ CORS_RULE_ELEMENT: string; /** * XML element for AllowedOrigins. * * @const * @type {string} * @default "AllowedOrigins" */ ALLOWED_ORIGINS_ELEMENT: string; /** * XML element for AllowedMethods. * * @const * @type {string} * @default "AllowedMethods" */ ALLOWED_METHODS_ELEMENT: string; /** * XML element for MaxAgeInSeconds. * * @const * @type {string} * @default "MaxAgeInSeconds" */ MAX_AGE_IN_SECONDS_ELEMENT: string; /** * XML element for ExposedHeaders. * * @const * @type {string} * @default "ExposedHeaders" */ EXPOSED_HEADERS_ELEMENT: string; /** * XML element for AllowedHeaders. * * @const * @type {string} * @default "AllowedHeaders" */ ALLOWED_HEADERS_ELEMENT: string; /** * XML element for IncludeAPIs. * * @const * @type {string} * @default "IncludeAPIs" */ INCLUDE_APIS_ELEMENT: string; /** * XML element for DefaultServiceVersion. * * @const * @type {string} * @default "DefaultServiceVersion" */ DEFAULT_SERVICE_VERSION_ELEMENT: string; }; /** * Defines constants for use with blob operations. */ export const BlobConstants: { /** * XML element for the latest. * * @const * @type {string} * @default "Latest" */ LATEST_ELEMENT: string; /** * XML element for uncommitted blocks. * * @const * @type {string} * @default "Uncommitted" */ UNCOMMITTED_ELEMENT: string; /** * XML element for a block list. * * @const * @type {string} * @default "BlockList" */ BLOCK_LIST_ELEMENT: string; /** * XML element for committed blocks. * * @const * @type {string} * @default "Committed" */ COMMITTED_ELEMENT: string; /** * The default write page size; in bytes; used by blob streams. * * @const * @type {int} */ DEFAULT_WRITE_PAGE_SIZE_IN_BYTES: number; /** * The minimum write page size; in bytes; used by blob streams. * * @const * @type {int} */ MIN_WRITE_PAGE_SIZE_IN_BYTES: number; /** * The default maximum size; in bytes; of a blob before it must be separated into blocks. * * @const * @type {int} */ DEFAULT_SINGLE_BLOB_PUT_THRESHOLD_IN_BYTES: number; /** * The default write block size; in bytes; used by blob streams. * * @const * @type {int} */ DEFAULT_WRITE_BLOCK_SIZE_IN_BYTES: number; /** * The maximum size of a single block. * * @const * @type {int} */ MAX_BLOCK_SIZE: number; /** * The maximum size; in bytes; of a blob before it must be separated into blocks. * * @const * @type {int} */ MAX_SINGLE_UPLOAD_BLOB_SIZE_IN_BYTES: number; /** * The maximum range get size when requesting for a contentMD5 */ MAX_RANGE_GET_SIZE_WITH_MD5: number; /** * The maximum page range size for a page update operation. */ MAX_UPDATE_PAGE_SIZE: number; /** * The maximum buffer size for writing a stream buffer. */ MAX_QUEUED_WRITE_DISK_BUFFER_SIZE: number; /** * Max size for single get page range. The max value should be 150MB * http://blogs.msdn.com/b/windowsazurestorage/archive/2012/03/26/getting-the-page-ranges-of-a-large-page-blob-in-segments.aspx */ MAX_SINGLE_GET_PAGE_RANGE_SIZE: number; /** * The size of a page; in bytes; in a page blob. */ PAGE_SIZE: number; /** * Resource types. * * @const * @enum {string} */ ResourceTypes: { /** * @const * @default "c" */ CONTAINER: string; /** * @const * @default "b" */ BLOB: string; }; /** * List blob types. * * @const * @enum {string} */ ListBlobTypes: { /** * @const * @default "b" */ Blob: string; /** * @const * @default "d" */ Directory: string; }; /** * Put page write options * * @const * @enum {string} */ PageWriteOptions: { /** * @const * @default "update" */ UPDATE: string; /** * @const * @default "clear" */ CLEAR: string; }; /** * Blob types * * @const * @enum {string} */ BlobTypes: { /** * @const * @default "BlockBlob" */ BLOCK: string; /** * @const * @default "PageBlob" */ PAGE: string; /** * @const * @default "AppendBlob" */ APPEND: string; }; /** * Blob lease constants * * @const * @enum {string} */ LeaseOperation: { /** * @const * @default "acquire" */ ACQUIRE: string; /** * @const * @default "renew" */ RENEW: string; /** * @const * @default "change" */ CHANGE: string; /** * @const * @default "release" */ RELEASE: string; /** * @const * @default "break" */ BREAK: string; } }; /** * Defines constants for use with file operations. */ export const FileConstants: { /** * The default write size; in bytes; used by file streams. * * @const * @type {string} */ DEFAULT_WRITE_SIZE_IN_BYTES: number; /** * The maximum range size when requesting for a contentMD5. */ MAX_RANGE_GET_SIZE_WITH_MD5: number; /** * The maximum range size for a file update operation. */ MAX_UPDATE_FILE_SIZE: number; /** * The default minimum size; in bytes; of a file when it must be separated into ranges. * * @const * @type {int} */ DEFAULT_SINGLE_FILE_GET_THRESHOLD_IN_BYTES: number; /** * The minimum write file size; in bytes; used by file streams. * * @const * @type {int} */ MIN_WRITE_FILE_SIZE_IN_BYTES: number; /** * Put range write options * * @const * @enum {string} */ RangeWriteOptions: { /** * @const * @default "update" */ UPDATE: string; /** * @const * @default "clear" */ CLEAR: string; }; /** * Resource types. * * @const * @enum {string} */ ResourceTypes: { /** * @const * @default "s" */ SHARE: string; /** * @const * @default "f" */ FILE: string; } }; /** * Defines constants for use with queue storage. * * @const * @type {string} */ export const QueueConstants: { /** * XML element for QueueMessage. * * @const * @type {string} * @default "QueueMessage" */ QUEUE_MESSAGE_ELEMENT: string; /** * XML element for MessageText. * * @const * @type {string} * @default "MessageText" */ MESSAGE_TEXT_ELEMENT: string; }; /** * Defines constants for use with table storage. * * @const * @type {string} */ export const TableConstants: { /** * The changeset response delimiter. * * @const * @type {string} * @default "--changesetresponse_" */ CHANGESET_DELIMITER: string; /** * The batch response delimiter. * * @const * @type {string} * @default "--batchresponse_" */ BATCH_DELIMITER: string; /** * The next continuation row key token. * * @const * @type {string} * @default "x-ms-continuation-nextrowkey" */ CONTINUATION_NEXT_ROW_KEY: string; /** * The next continuation partition key token. * * @const * @type {string} * @default "x-ms-continuation-nextpartitionkey" */ CONTINUATION_NEXT_PARTITION_KEY: string; /** * The next continuation table name token. * * @const * @type {string} * @default "x-ms-continuation-nexttablename" */ CONTINUATION_NEXT_TABLE_NAME: string; /** * The next row key query string argument. * * @const * @type {string} * @default "NextRowKey" */ NEXT_ROW_KEY: string; /** * The next partition key query string argument. * * @const * @type {string} * @default "NextPartitionKey" */ NEXT_PARTITION_KEY: string; /** * The next table name query string argument. * * @const * @type {string} * @default "NextTableName" */ NEXT_TABLE_NAME: string; /** * Prefix of the odata properties returned in a JSON query * @default "odata." */ ODATA_PREFIX: string; /** * Constant representing the string following a type annotation in a JSON table query * @default "@odata.type" */ ODATA_TYPE_SUFFIX: string; /** * Constant representing the property where the odata metadata elements are stored. * * @const * @type {string} * @default ".metadata" */ ODATA_METADATA_MARKER: string; /** * Constant representing the value for an entity property. * @default "_" */ ODATA_VALUE_MARKER: string; /** * Constant representing the type for an entity property. * @default "$" */ ODATA_TYPE_MARKER: string; /** * The value to set the maximum data service version header. * @const * @type {string} * @default "3.0;NetFx" */ DEFAULT_DATA_SERVICE_VERSION: string; /** * The name of the property that stores the table name. * * @const * @type {string} * @default "TableName" */ TABLE_NAME: string; /** * The name of the special table used to store tables. * * @const * @type {string} * @default "Tables" */ TABLE_SERVICE_TABLE_NAME: string; /** * Operations * * @const *