Options
All
  • Public
  • Public/Protected
  • All
Menu

Class Workspace

A workspace.

Hierarchy

  • WorkspaceBase
    • Workspace

Implements

Index

Constructors

Properties

Accessors

Methods

Constructors

constructor

  • Initializes a new instance of that class.

    Parameters

    • id: any

      The ID.

    • folder: vscode.WorkspaceFolder

      The underlying folder.

    • context: WorkspaceContext

      the current extension context.

    Returns Workspace

Properties

Private _APIS

_APIS: ApiHost[] = []

Private _AUTO_DEPLOY_QUEUE

_AUTO_DEPLOY_QUEUE: PQueue<DefaultAddOptions> = deploy_helpers.createQueue()

Private _CONFIG_FILE_WATCHERS

_CONFIG_FILE_WATCHERS: vscode.FileSystemWatcher[] = []

Private _DEACTIVATE_AUTO_DEPLOY_FOR_QUEUE

_DEACTIVATE_AUTO_DEPLOY_FOR_QUEUE: PQueue<DefaultAddOptions> = deploy_helpers.createQueue()

Private _DEPLOY_QUEUE

_DEPLOY_QUEUE: PQueue<DefaultAddOptions> = deploy_helpers.createQueue()

Protected _DISPOSABLES

_DISPOSABLES: vscode.Disposable[]

Stores disposable sub objects.

Protected _INTERVALS

_INTERVALS: Timer[]

Stores intervals.

Private _LOGGER

_LOGGER: ActionLogger = new deploy_log.ActionLogger()

Private _OLD_ENV_VARS

_OLD_ENV_VARS: deploy_contracts.KeyValuePairs

Private _OUTPUT_CHANNEL

_OUTPUT_CHANNEL: OutputChannelWrapper

Private _PACKAGE_BUTTONS

_PACKAGE_BUTTONS: PackageWithButton[] = []

Private _QUEUE

_QUEUE: PQueue<DefaultAddOptions> = deploy_helpers.createQueue()

Private _SWITCH_BUTTONS

_SWITCH_BUTTONS: TargetWithButton<SwitchTarget>[] = []

Private _TCP_PROXIES

_TCP_PROXIES: TcpProxyDestinationContext[] = []

The current translation function.

Private _TCP_PROXY_BUTTONS

_TCP_PROXY_BUTTONS: TcpProxyButton[] = []

Private _TCP_PROXY_FILTERS

_TCP_PROXY_FILTERS: TcpProxyRemoteFilterContext[] = []

Private _TCP_PROXY_LOGGERS

_TCP_PROXY_LOGGERS: TcpProxyLoggingContext[] = []

Private _TCP_PROXY_NAMES_AND_DESCS

_TCP_PROXY_NAMES_AND_DESCS: TcpProxyNameAndDescriptionResolverContext[] = []

Protected _TIMEOUTS

_TIMEOUTS: Timer[]

Stores timeouts.

Protected _config

Stores the current configuration.

Protected _configSource

_configSource: WorkspaceConfigSource

Stores the source of the configuration data.

Private _gitFolder

_gitFolder: string | false

Private _isDeployOnChangeFreezed

_isDeployOnChangeFreezed: boolean = false

Private _isDeployOnSaveFreezed

_isDeployOnSaveFreezed: boolean = false

Protected _isInitialized

_isInitialized: boolean = false

Stores if workspace has been initialized or not.

Protected _isReloadingConfig

_isReloadingConfig: boolean = false

Stores if configuration is currently reloaded or not.

Private _isRemoveOnChangeFreezed

_isRemoveOnChangeFreezed: boolean = false

Protected _lastConfigUpdate

_lastConfigUpdate: Moment.Moment

Stores the last timestamp of configuration update.

Private _packages

_packages: Package[]

Private _rootPath

_rootPath: string | false

Private _selectedSwitches

_selectedSwitches: deploy_contracts.KeyValuePairs

Protected _startTime

_startTime: Moment.Moment

Stores the start time.

Private _targets

_targets: Target[]

Protected _translator

_translator: i18next.TranslationFunction

Private _workspaceSessionState

_workspaceSessionState: deploy_contracts.KeyValuePairs

context

the current extension context.

folder

folder: vscode.WorkspaceFolder

id

id: any

The ID.

isDisposed

isDisposed: boolean

Gets if object has been disposed or not.

isDisposing

isDisposing: boolean

Gets if the 'dispose()' method is currently executed or not.

isInFinalizeState

isInFinalizeState: boolean

Gets if the object is disposed or currently disposing.

state

Stores the memento of that workspace.

vars

vars: deploy_contracts.KeyValuePairs

A storage of variables for that object.

Static defaultMaxListeners

defaultMaxListeners: number

Accessors

canDoAutoOperations

  • get canDoAutoOperations(): boolean
  • Gets if the workspace can do automatic (background) operations or not.

    Returns boolean

config

configSource

deployQueue

  • get deployQueue(): PQueue<DefaultAddOptions>
  • Gets the workspace-wide queue for all deploy processes.

    Returns PQueue<DefaultAddOptions>

editorRootPath

  • get editorRootPath(): string

gitFolder

  • get gitFolder(): string | false
  • Gets the path to the '.git' folder (if available).

    Returns string | false

globals

  • get globals(): any

isActive

  • get isActive(): boolean

isDeployOnChangeFreezed

  • get isDeployOnChangeFreezed(): boolean
  • set isDeployOnChangeFreezed(newValue: boolean): void
  • Gets or sets if 'deploy on change' is currently freezed or not.

    Returns boolean

  • Gets or sets if 'deploy on change' is currently freezed or not.

    Parameters

    • newValue: boolean

    Returns void

isDeployOnSaveFreezed

  • get isDeployOnSaveFreezed(): boolean
  • set isDeployOnSaveFreezed(newValue: boolean): void
  • Gets or sets if 'deploy on change' is currently freezed or not.

    Returns boolean

  • Gets or sets if 'deploy on change' is currently freezed or not.

    Parameters

    • newValue: boolean

    Returns void

isInitialized

  • get isInitialized(): boolean
  • Gets if the workspace has been initialized or not.

    Returns boolean

isReloadingConfig

  • get isReloadingConfig(): boolean
  • Gets if the configuration for that workspace is currently reloaded or not.

    Returns boolean

isRemoveOnChangeFreezed

  • get isRemoveOnChangeFreezed(): boolean
  • set isRemoveOnChangeFreezed(newValue: boolean): void
  • Gets or sets if 'remove on change' is currently freezed or not.

    Returns boolean

  • Gets or sets if 'remove on change' is currently freezed or not.

    Parameters

    • newValue: boolean

    Returns void

lastConfigUpdate

  • get lastConfigUpdate(): Moment.Moment
  • Gets the last config update timestamp.

    Returns Moment.Moment

logger

  • get logger(): Logger

name

  • get name(): string

output

  • get output(): vscode.OutputChannel
  • Gets the output channel of that workspace.

    Returns vscode.OutputChannel

queue

  • get queue(): PQueue<DefaultAddOptions>
  • Gets the workspace-wide queue.

    Returns PQueue<DefaultAddOptions>

rootPath

  • get rootPath(): string
  • Gets the root path of that workspace.

    Returns string

selectedSwitches

  • get selectedSwitches(): deploy_contracts.KeyValuePairs
  • Gets the repository of selected switches.

    Returns deploy_contracts.KeyValuePairs

settingFolder

  • get settingFolder(): string

startTime

  • get startTime(): Moment.Moment

syncWhenOpenStates

workspaceSessionState

  • get workspaceSessionState(): deploy_contracts.KeyValuePairs
  • Gets the current session data storage.

    Returns deploy_contracts.KeyValuePairs

Methods

addListener

  • addListener(event: string | symbol, listener: Function): this
  • Parameters

    • event: string | symbol
    • listener: Function

    Returns this

applyValuesTo

  • applyValuesTo<TObj>(obj: TObj): TObj
  • Applies values to an object.

    Type parameters

    Parameters

    • obj: TObj

      The object to apply the values to.

    Returns TObj

    The new object.

canBeHandledByMe

changeSwitchButtonOption

  • changeSwitchButtonOption(target: SwitchTarget): Promise<void>

Private checkForRequiredExtensions

Private checkForRequirements

Protected cleanupIntervals

  • cleanupIntervals(): void
  • Cleansup all timeouts.

    Returns void

Private cleanupPackageButtons

  • cleanupPackageButtons(): void

Private cleanupSwitchButtons

  • cleanupSwitchButtons(): void

Protected cleanupTimeouts

  • cleanupTimeouts(): void
  • Cleansup all timeouts.

    Returns void

createGitClient

  • createGitClient(): Promise<GitClient | false>
  • Creates a new git client (if possible).

    Returns Promise<GitClient | false>

    The promise with the client or (false) if not found.

createLogger

  • createLogger(): Logger
  • Creates a (new) logger based of that workspace.

    Returns Logger

    The (new) workspace logger.

Private createWorkspaceSessionState

deactivateAutoDeployOperationsFor

  • Deactivates auto deploy operations like 'deploy on change', 'deploy on save' and 'remove on change' while an action is running.

    Type parameters

    • TResult

    Parameters

    Returns Promise<TResult>

    The promise with the result of the action.

deleteFileIn

  • deleteFileIn(file: string, target: Target, askForDeleteLocalFile?: boolean): Promise<any>
  • Deletes a file in a target.

    Parameters

    • file: string

      The file to delete.

    • target: Target

      The target to delete in.

    • Default value askForDeleteLocalFile: boolean = true

    Returns Promise<any>

deletePackage

  • deletePackage(pkg: Package, targetResolver?: deploy_targets.TargetResolver, askForDeleteLocalFiles?: boolean): Promise<void>
  • Deletes a package.

    Parameters

    • pkg: Package

      The package to delete.

    • Optional targetResolver: deploy_targets.TargetResolver
    • Default value askForDeleteLocalFiles: boolean = true

    Returns Promise<void>

deployFileTo

  • deployFileTo(file: string, target: Target): Promise<any>
  • Deploys a file to a target.

    Parameters

    • file: string

      The file to deploy.

    • target: Target

      The target to deploy to.

    Returns Promise<any>

Protected deployFilesTo

  • deployFilesTo(files: string[], target: Target, targetNr?: number): Promise<any>
  • Deploys a files to a target.

    Parameters

    • files: string[]

      The files to deploy.

    • target: Target

      The target to deploy to.

    • Optional targetNr: number

    Returns Promise<any>

deployGitCommit

  • deployGitCommit(target: Target): Promise<void>
  • Deploys files of a git commit.

    Parameters

    • target: Target

      The target to deploy to.

    Returns Promise<void>

Protected deployOnChange

  • deployOnChange(file: string): Promise<any>
  • Deploys a file when is has been changed.

    Parameters

    • file: string

      The file to check.

    Returns Promise<any>

Protected deployOnSave

  • deployOnSave(file: string): Promise<any>
  • Deploys a file when is has been saved.

    Parameters

    • file: string

      The file to check.

    Returns Promise<any>

deployPackage

  • deployPackage(pkg: Package, targetResolver?: deploy_targets.TargetResolver): Promise<void>
  • Deploys a package.

    Parameters

    • pkg: Package

      The package to deploy.

    • Optional targetResolver: deploy_targets.TargetResolver

    Returns Promise<void>

deployUncomittedGitChanges

  • deployUncomittedGitChanges(target: Target): Promise<void>
  • Deploys uncomitted files of the git repository.

    Parameters

    • target: Target

      The target to deploy to.

    Returns Promise<void>

dispose

  • dispose(): void
  • inheritdoc

    Returns void

Private disposeAutoDeployButtons

  • disposeAutoDeployButtons(): void

Private disposeConfigFileWatchers

  • disposeConfigFileWatchers(): void

Private disposeTcpProxies

  • disposeTcpProxies(): void

emit

  • emit(event: string | symbol, ...args: any[]): boolean
  • Parameters

    • event: string | symbol
    • Rest ...args: any[]

    Returns boolean

eventNames

  • eventNames(): (string | symbol)[]
  • Returns (string | symbol)[]

exec

  • exec(command: string, opts?: ExecOptions): Promise<ExecResult>
  • Executes something for that workspace.

    Parameters

    • command: string

      The thing / command to execute.

    • Optional opts: ExecOptions

    Returns Promise<ExecResult>

    The promise with the result.

Private executeOnStartup

filterConditionalItems

  • filterConditionalItems<TItem>(items: TItem | TItem[], throwOnError?: boolean, errorResult?: any): TItem[]
  • Filters items with 'if' code.

    Type parameters

    Parameters

    • items: TItem | TItem[]

      The items to filter.

    • Default value throwOnError: boolean = false
    • Default value errorResult: any = false

    Returns TItem[]

    The filtered items.

findFilesByFilter

  • findFilesByFilter(filter: FileFilter, opts?: Glob.IOptions): Promise<string[]>
  • Finds files inside that workspace.

    Parameters

    • filter: FileFilter

      The filter to use.

    • Optional opts: Glob.IOptions

    Returns Promise<string[]>

    The promise with the found files.

findFilesByFilterFast

  • findFilesByFilterFast(filter: FileFilter, opts?: deploy_helpers.FastGlobOptions): Promise<(string | IFastGlobEntry)[]>
  • Finds files inside that workspace.

    Parameters

    • filter: FileFilter

      The filter to use.

    • Optional opts: deploy_helpers.FastGlobOptions

    Returns Promise<(string | IFastGlobEntry)[]>

    The promise with the found files.

Private getAllSwitchOptions

getApiHosts

  • Returns a list of all API hosts handled by that workspace.

    Returns ApiHost[]

    The list of hosts.

getDeletePlugins

getDownloadPlugins

getDownloadTargets

  • getDownloadTargets(): Target[]

getExistingSettingPath

  • getExistingSettingPath(path: string): Promise<string | false>
  • Returns an existing path based on the settings folder.

    Parameters

    • path: string

      The path.

    Returns Promise<string | false>

    The promise with the existing, full normalized path or (false) if path does not exist.

getFileListFromActiveDocumentForDeployment

  • getFileListFromActiveDocumentForDeployment(): Promise<string[] | false>
  • Returns the list of files of that workspace for deployment from an active document.

    Returns Promise<string[] | false>

    The promise with the file list or (false) if not possible.

getFinishedButton

  • Returns a status bar button, that shows if a deploy operation has been finished.

    Parameters

    Returns vscode.StatusBarItem

    The button.

getListPlugins

getMaxListeners

  • getMaxListeners(): number
  • Returns number

getPackageId

  • getPackageId(pkg: Package): string | false
  • Returns the ID of a package.

    Parameters

    Returns string | false

    The ID or (false) if package is invalid.

getPackages

Private getPopupPrefix

  • getPopupPrefix(): string

getRemoveFolderPlugins

getSelectedSwitchOption

getSettingScopes

  • getSettingScopes(): string[]
  • Returns the scope directories for settings.

    Returns string[]

    The list of scope directories.

Private getSwitchOptionName

Private getSwitchRepository

getSwitchTargets

getSyncWhenOpenKey

  • getSyncWhenOpenKey(target: Target): string | false
  • Returns the state key for 'sync when open'.

    Parameters

    Returns string | false

    The key or (false) when failed.

getTargetId

  • getTargetId(target: Target): string | false
  • Returns the ID of a target.

    Parameters

    Returns string | false

    The ID or (false) if target is invalid.

getTargets

getTargetsOfPackage

  • getTargetsOfPackage(pkg: Package, targetResolver: deploy_targets.TargetResolver): Target[] | false
  • Returns the targets of a package.

    Parameters

    • pkg: Package

      The package.

    • targetResolver: deploy_targets.TargetResolver

      A function to receive optional targets.

    Returns Target[] | false

    The targets or (false) if at least one target could not be found or (false) if package cannot be handled by that workspace.

getTargetsOfSwitch

  • Returns the children of a switch target.

    Parameters

    Returns Target[] | false

    The targets or (false) if failed.

getTcpProxies

  • Returns a list of all TCP proxies handled by that workspace.

    Returns TcpProxy[]

    The list of proxies.

getUploadPlugins

getUploadTargets

  • getUploadTargets(): Target[]

getValues

Private initBower

Private initComposer

Private initConfigFileWatchers

  • initConfigFileWatchers(files: string[]): Promise<void>

Private initNodeModules

initialize

  • initialize(): Promise<boolean>
  • Initializes that workspace.

    Returns Promise<boolean>

    The promise that indicates if operation was successful or not.

invokeForFinishedButton

  • invokeForFinishedButton(operation: DeployOperation, action: function): Promise<boolean>
  • Invokes an action for a status bar button that is shown after a deploy operation.

    Parameters

    • operation: DeployOperation

      The operation type.

    • action: function

      The action to invoke.

        • (btn: vscode.StatusBarItem): any
        • Parameters

          • btn: vscode.StatusBarItem

          Returns any

    Returns Promise<boolean>

    The promise that indicates if operation was successful or not.

isFileIgnored

  • isFileIgnored(file: string): boolean
  • Checks if a file is ignored by that workspace.

    Parameters

    • file: string

      The file to check.

    Returns boolean

    Is ignored or not.

Private isInFolder

  • isInFolder(folder: string, pathToCheck: string): boolean
  • Parameters

    • folder: string
    • pathToCheck: string

    Returns boolean

isInGitFolder

  • isInGitFolder(path: string): boolean
  • Checks if a path is inside the Git folder.

    Parameters

    • path: string

      The path to check.

    Returns boolean

    Is in Git folder or not.

isInSettingsFolder

  • isInSettingsFolder(path: string): boolean
  • Checks if a path is inside the settings folder.

    Parameters

    • path: string

      The path to check.

    Returns boolean

    Is in settings folder or not.

isInSvnFolder

  • isInSvnFolder(path: string): boolean
  • Checks if a path is inside the Git folder.

    Parameters

    • path: string

      The path to check.

    Returns boolean

    Is in Git folder or not.

isPathOf

  • isPathOf(path: string): boolean
  • Checks if a path is part of that workspace.

    Parameters

    • path: string

      The path to check.

    Returns boolean

    Is part of that workspace or not.

listDirectory

  • List the root directory on a target.

    Type parameters

    Parameters

    • target: TTarget

      The target from where to get the list.

    Returns Promise<ListDirectoryResult<TTarget>>

    The promise with the result.

listWorkspaceDirectory

listenerCount

  • listenerCount(type: string | symbol): number
  • Parameters

    • type: string | symbol

    Returns number

listeners

  • listeners(event: string | symbol): Function[]
  • Parameters

    • event: string | symbol

    Returns Function[]

loadDataTransformer

  • loadDataTransformer(transformable: CanTransformData): Promise<deploy_transformers.DataTransformer | false>
  • Loads a data transformer for an object.

    Parameters

    Returns Promise<deploy_transformers.DataTransformer | false>

    The loaded transformer or (false) if script could not be loaded.

on

  • on(event: string | symbol, listener: Function): this
  • Parameters

    • event: string | symbol
    • listener: Function

    Returns this

onDidChangeActiveTextEditor

  • onDidChangeActiveTextEditor(editor: vscode.TextEditor): Promise<void>
  • Is invoked when the active text editor changed.

    Parameters

    • editor: vscode.TextEditor

      The new editor.

    Returns Promise<void>

onDidChangeConfiguration

  • onDidChangeConfiguration(e: vscode.ConfigurationChangeEvent): Promise<void>
  • Is invoked when configuration changes.

    Parameters

    • e: vscode.ConfigurationChangeEvent

      The event data.

    Returns Promise<void>

Private onDidFileChange

  • onDidFileChange(e: vscode.Uri, type: FileChangeType, retry?: boolean): Promise<void>

onDidSaveTextDocument

  • onDidSaveTextDocument(e: vscode.TextDocument): Promise<void>
  • Is invoked when a text document has been changed.

    Parameters

    • e: vscode.TextDocument

      The underlying text document.

    Returns Promise<void>

Protected onDispose

  • onDispose(): void
  • inheritdoc

    Returns void

once

  • once(event: string | symbol, listener: Function): this
  • Parameters

    • event: string | symbol
    • listener: Function

    Returns this

prepareTarget

  • prepareTarget<TTarget>(target: TTarget): TTarget
  • Prepares a target for deployment.

    Type parameters

    Parameters

    • target: TTarget

      The target to prepare.

    Returns TTarget

    The prepared target.

prependListener

  • prependListener(event: string | symbol, listener: Function): this
  • Parameters

    • event: string | symbol
    • listener: Function

    Returns this

prependOnceListener

  • prependOnceListener(event: string | symbol, listener: Function): this
  • Parameters

    • event: string | symbol
    • listener: Function

    Returns this

pullFileFrom

  • pullFileFrom(file: string, target: Target): Promise<any>
  • Pulls a file from a target.

    Parameters

    • file: string

      The file to pull.

    • target: Target

      The target from where to pull from.

    Returns Promise<any>

Protected pullFilesFrom

  • pullFilesFrom(files: string[], target: Target, targetNr?: number): Promise<any>
  • Pulls files from a target.

    Parameters

    • files: string[]

      The files to pull.

    • target: Target

      The target to pull from.

    • Optional targetNr: number

    Returns Promise<any>

pullPackage

  • pullPackage(pkg: Package, targetResolver?: deploy_targets.TargetResolver): Promise<void>
  • Pulls a package.

    Parameters

    • pkg: Package

      The package to pull.

    • Optional targetResolver: deploy_targets.TargetResolver

    Returns Promise<void>

Private reloadAutoDeployButtons

  • reloadAutoDeployButtons(): Promise<void>

reloadConfiguration

  • reloadConfiguration(retry?: boolean): Promise<void>
  • Reloads the current configuration for that workspace.

    Parameters

    • Default value retry: boolean = true

    Returns Promise<void>

reloadEnvVars

  • reloadEnvVars(): void
  • Reloads the environment variables as defined in the settings.

    Returns void

Private reloadPackageButtons

  • reloadPackageButtons(): Promise<void>

Private reloadPackages

Private reloadSwitches

  • reloadSwitches(): Promise<void>

Private reloadTargets

Private reloadTcpProxies

  • reloadTcpProxies(): Promise<void>

removeAllListeners

  • removeAllListeners(event?: string | symbol): this
  • Parameters

    • Optional event: string | symbol

    Returns this

removeListener

  • removeListener(event: string | symbol, listener: Function): this
  • Parameters

    • event: string | symbol
    • listener: Function

    Returns this

Protected removeOnChange

  • removeOnChange(file: string): Promise<void>
  • Handles a file for "remove on change" feature.

    Parameters

    • file: string

      The file to check.

    Returns Promise<void>

replaceWithValues

  • replaceWithValues(val: any, additionalValuesOrThrowOnError?: Value | Value[] | boolean, throwOnError?: boolean): string
  • Handles a value as string and replaces placeholders.

    Parameters

    • val: any

      The value to parse.

    • Default value additionalValuesOrThrowOnError: Value | Value[] | boolean = true
    • Default value throwOnError: boolean = true

    Returns string

    The parsed value.

setMaxListeners

  • setMaxListeners(n: number): this
  • Parameters

    • n: number

    Returns this

setTimeoutForFinishedButton

  • setTimeoutForFinishedButton(operation: DeployOperation, callback: function, ms?: number): boolean
  • Sets a timeout for a "finished button".

    Parameters

    • operation: DeployOperation

      The type of deploy operation.

    • callback: function

      The callback.

        • (btn: vscode.StatusBarItem): any
        • Parameters

          • btn: vscode.StatusBarItem

          Returns any

    • Default value ms: number = 60000

    Returns boolean

    Operation was successful or not.

Private setupLogger

  • setupLogger(): void

Private setupOutputChannel

  • setupOutputChannel(): void

showErrorMessage

  • showErrorMessage<TItem>(msg: any, ...items: TItem[]): Promise<TItem>
  • Promise (and safe) version of 'vscode.window.showErrorMessage()' function.

    Type parameters

    • TItem: vscode.MessageItem

    Parameters

    • msg: any

      The message to display.

    • Rest ...items: TItem[]

    Returns Promise<TItem>

    The promise with the selected item.

showFinishedButton

  • Shows a "finished button".

    Parameters

    Returns boolean

    Operation was successful or not.

showInformationMessage

  • showInformationMessage<TItem>(msg: any, ...items: TItem[]): Promise<TItem>
  • Promise (and safe) version of 'vscode.window.showErrorMessage()' function.

    Type parameters

    • TItem: vscode.MessageItem

    Parameters

    • msg: any

      The message to display.

    • Rest ...items: TItem[]

    Returns Promise<TItem>

    The promise with the selected item.

showTargetQuickPick

  • showTargetQuickPick(opts?: vscode.QuickPickOptions): Promise<Target | false>
  • Shows a quick pick for a list of targets of that workspace.

    Parameters

    • Optional opts: vscode.QuickPickOptions

    Returns Promise<Target | false>

    The promise that contains the selected target (if selected) or (false) if no target is available.

showWarningMessage

  • showWarningMessage<TItem>(msg: any, ...items: TItem[]): Promise<TItem>
  • Promise (and safe) version of 'vscode.window.showWarningMessage()' function.

    Type parameters

    • TItem: vscode.MessageItem

    Parameters

    • msg: any

      The message to display.

    • Rest ...items: TItem[]

    Returns Promise<TItem>

    The promise with the selected item.

startDeploymentOfFilesFromActiveDocument

  • startDeploymentOfFilesFromActiveDocument(deployAction: function): Promise<boolean>
  • Starts a deployment of files from the file list of an active document.

    Parameters

    • deployAction: function

      The deploy action.

        • (target: Target, files: string[]): any
        • Parameters

          • target: Target
          • files: string[]

          Returns any

    Returns Promise<boolean>

    The promise that indicates if action has been invoked or not.

t

  • t(key: string, ...args: any[]): string
  • inheritdoc

    Parameters

    • key: string
    • Rest ...args: any[]

    Returns string

toFullPath

  • toFullPath(path: string): string | false
  • Converts to a full path.

    Parameters

    • path: string

      The path to convert.

    Returns string | false

    The pull path or (false) if 'path' could not be converted.

toNameAndPath

  • Extracts the name and (relative) path from a file.

    Parameters

    • file: string

      The file (path).

    Returns WithNameAndPath | false

    The extracted data or (false) if file path is invalid.

toRelativePath

  • toRelativePath(path: string): string | false
  • Converts to a relative path.

    Parameters

    • path: string

      The path to convert.

    Returns string | false

    The relative path or (false) if 'path' could not be converted.

Private updateAutoDeployButtons

  • updateAutoDeployButtons(): void

Private updateSwitchButtons

  • updateSwitchButtons(): Promise<void>

Static listenerCount

  • listenerCount(emitter: EventEmitter, event: string | symbol): number
  • Parameters

    • emitter: EventEmitter
    • event: string | symbol

    Returns number

Generated using TypeDoc