Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
export namespace DeleteAgentAlertRequest {
export const type = new RequestType('agent/deletealert');
}
// Operators requests
export namespace AgentOperatorsRequest {
export const type = new RequestType('agent/operators');
}
export namespace CreateAgentOperatorRequest {
export const type = new RequestType('agent/createoperator');
}
export namespace UpdateAgentOperatorRequest {
export const type = new RequestType('agent/updateoperator');
}
export namespace DeleteAgentOperatorRequest {
export const type = new RequestType('agent/deleteoperator');
}
// Proxies requests
export namespace AgentProxiesRequest {
export const type = new RequestType('agent/proxies');
}
export namespace CreateAgentProxyRequest {
export const type = new RequestType('agent/createproxy');
}
export namespace UpdateAgentProxyRequest {
/*---------------------------------------------------------------------------------------------
* Copyright (c) Microsoft Corporation. All rights reserved.
* Licensed under the MIT License. See License.txt in the project root for license information.
*--------------------------------------------------------------------------------------------*/
'use strict';
import {RequestType} from 'vscode-languageclient';
import {Runtime, LinuxDistribution} from '../platform';
// --------------------------------- < Version Request > -------------------------------------------------
// Version request message callback declaration
export namespace VersionRequest {
export const type = new RequestType('version');
}
// Version response format
export type VersionResult = string;
// ------------------------------- --------------------------------------------------
// Constants interface for each extension
export interface IExtensionConstants {
// TODO: Fill in interface
// Definitely dependent on the extension
extensionName: string;
invalidServiceFilePath: string;
serviceName: string;
extensionConfigSectionName: string;
import {
ColorPresentationParams,
ColorPresentationRequest,
DocumentColorParams,
DocumentColorRequest
} from 'vscode-languageserver-protocol';
import { telemetryService } from './telemetry';
// tslint:disable-next-line:no-namespace
namespace TagCloseRequest {
export const type: RequestType<
TextDocumentPositionParams,
string,
any,
any
> = new RequestType('html/tag');
}
export async function activate(context: ExtensionContext) {
const extensionHRStart = process.hrtime();
const toDispose = context.subscriptions;
// The server is implemented in node
const serverModule = context.asAbsolutePath(
path.join(
'node_modules',
'@salesforce',
'salesforcedx-visualforce-language-server',
'out',
'src',
'visualforceServer.js'
)
export namespace UpdateAgentOperatorRequest {
export const type = new RequestType('agent/updateoperator');
}
export namespace DeleteAgentOperatorRequest {
export const type = new RequestType('agent/deleteoperator');
}
// Proxies requests
export namespace AgentProxiesRequest {
export const type = new RequestType('agent/proxies');
}
export namespace CreateAgentProxyRequest {
export const type = new RequestType('agent/createproxy');
}
export namespace UpdateAgentProxyRequest {
export const type = new RequestType('agent/updateproxy');
}
export namespace DeleteAgentProxyRequest {
export const type = new RequestType('agent/deleteproxy');
}
// Agent Credentials request
export namespace AgentCredentialsRequest {
export const type = new RequestType('security/credentials');
}
// Job Schedules requests
export interface RefactorWorkspaceEdit {
edit: WorkspaceEdit;
command?: Command;
errorMessage?: string;
}
export interface GetRefactorEditParams {
command: string;
context: CodeActionParams;
options: FormattingOptions;
commandArguments: any[];
}
export namespace GetRefactorEditRequest {
export const type = new RequestType('java/getRefactorEdit');
}
export interface PackageNode {
displayName: string;
uri: string;
path: string;
project: string;
isDefaultPackage: boolean;
isParentOfSelectedFile: boolean;
}
export interface MoveParams {
moveKind: string;
sourceUris: string[];
params: CodeActionParams;
destination?: any;
/*---------------------------------------------------------
* Copyright (C) Microsoft Corporation. All rights reserved.
*--------------------------------------------------------*/
import vscode = require("vscode");
import { LanguageClient, RequestType } from "vscode-languageclient";
import { ICheckboxQuickPickItem, showCheckboxQuickPick } from "../controls/checkboxQuickPick";
import { IFeature } from "../feature";
import { Logger } from "../logging";
export const GetPSSARulesRequestType = new RequestType("powerShell/getPSSARules");
export const SetPSSARulesRequestType = new RequestType("powerShell/setPSSARules");
class RuleInfo {
public name: string;
public isEnabled: boolean;
}
export class SelectPSSARulesFeature implements IFeature {
private command: vscode.Disposable;
private languageClient: LanguageClient;
constructor(private log: Logger) {
this.command = vscode.commands.registerCommand("PowerShell.SelectPSSARules", () => {
if (this.languageClient === undefined) {
this.log.writeAndShowError(`<${SelectPSSARulesFeature.name}>: ` +
constructors: MethodBinding[];
fields: VariableBinding[];
}
export namespace CheckConstructorStatusRequest {
export const type = new RequestType('java/checkConstructorsStatus');
}
export interface GenerateConstructorsParams {
context: CodeActionParams;
constructors: MethodBinding[];
fields: VariableBinding[];
}
export namespace GenerateConstructorsRequest {
export const type = new RequestType('java/generateConstructors');
}
export interface DelegateField {
field: VariableBinding;
delegateMethods: MethodBinding[];
}
export interface CheckDelegateMethodsResponse {
delegateFields: DelegateField[];
}
export namespace CheckDelegateMethodsStatusRequest {
export const type = new RequestType('java/checkDelegateMethodsStatus');
}
export interface DelegateEntry {
import * as path from 'path';
import { workspace, languages, ExtensionContext, extensions, Uri, Range } from 'vscode';
import { LanguageClient, LanguageClientOptions, RequestType, ServerOptions, TransportKind, NotificationType } from 'vscode-languageclient';
import { activateColorDecorations } from "./colorDecorators";
import * as nls from 'vscode-nls';
let localize = nls.loadMessageBundle();
namespace VSCodeContentRequest {
export const type: RequestType = new RequestType('vscode/content');
}
namespace ColorSymbolRequest {
export const type: RequestType = new RequestType('yaml/colorSymbols');
}
export interface ISchemaAssociations {
[pattern: string]: string[];
}
namespace SchemaAssociationNotification {
export const type: NotificationType = new NotificationType('json/schemaAssociations');
}
interface IPackageInfo {
name: string;
version: string;
aiKey: string;
}
type FileType = 0 | 1 | 2 | 64;
interface FileStat {
type: FileType;
ctime: number;
mtime: number;
size: number;
}
interface StatFileParams {
uri: string;
}
namespace StatFileRequest {
export const type = new RequestType('lsif/statFile');
}
interface ReadFileParams {
uri: string;
}
namespace ReadFileRequest {
export const type = new RequestType('lsif/readfile');
}
interface ReadDirectoryParams {
uri: string;
}
namespace ReadDirectoryRequest {
export const type = new RequestType('lsif/readDirectory');
identifer: string;
files: string[];
}
export interface DocumentScriptInfo {
identifiers: string[];
identifierFiles: IdentifierFiles[];
searchPaths: string[];
}
export interface ProvideDocumentScriptInfoSignature {
(document: TextDocument, token: CancellationToken): ProviderResult;
}
export const documentScriptInfoRequestType = {
type: new RequestType(
'textDocument/scriptInfo'
),
};
export interface RegistryInstallPathParams {
RegKeyName: string;
}
export interface RegistryInstallPathInfo {
value: string;
exists: boolean;
}
export const documentRegistryInstallPathRequestType = {
type: new RequestType(
'textDocument/registryInstallPath'