Update API (#24966)
This commit is contained in:
parent
e0109ea93e
commit
911658bbd2
1 changed files with 14 additions and 0 deletions
|
@ -10832,6 +10832,18 @@ declare namespace ts {
|
|||
forEach(cb: (node: Node) => void): void;
|
||||
some(pred: (node: Node) => boolean): boolean;
|
||||
}
|
||||
interface ReadonlyNodeMap<TNode extends Node, TValue> {
|
||||
get(node: TNode): TValue | undefined;
|
||||
has(node: TNode): boolean;
|
||||
}
|
||||
class NodeMap<TNode extends Node, TValue> implements ReadonlyNodeMap<TNode, TValue> {
|
||||
private map;
|
||||
get(node: TNode): TValue | undefined;
|
||||
getOrUpdate(node: TNode, setValue: () => TValue): TValue;
|
||||
set(node: TNode, value: TValue): void;
|
||||
has(node: TNode): boolean;
|
||||
forEach(cb: (value: TValue, node: TNode) => void): void;
|
||||
}
|
||||
function getParentNodeInSpan(node: Node | undefined, file: SourceFile, span: TextSpan): Node | undefined;
|
||||
function findModifier(node: Node, kind: Modifier["kind"]): Modifier | undefined;
|
||||
function insertImport(changes: textChanges.ChangeTracker, sourceFile: SourceFile, importDecl: Statement): void;
|
||||
|
@ -11592,8 +11604,10 @@ declare namespace ts {
|
|||
function getSupportedErrorCodes(): string[];
|
||||
function getFixes(context: CodeFixContext): CodeFixAction[];
|
||||
function getAllFixes(context: CodeFixAllContext): CombinedCodeActions;
|
||||
function createCombinedCodeActions(changes: FileTextChanges[], commands?: CodeActionCommand[]): CombinedCodeActions;
|
||||
function createFileTextChanges(fileName: string, textChanges: TextChange[]): FileTextChanges;
|
||||
function codeFixAll(context: CodeFixAllContext, errorCodes: number[], use: (changes: textChanges.ChangeTracker, error: DiagnosticWithLocation, commands: Push<CodeActionCommand>) => void): CombinedCodeActions;
|
||||
function eachDiagnostic({ program, sourceFile, cancellationToken }: CodeFixAllContext, errorCodes: number[], cb: (diag: DiagnosticWithLocation) => void): void;
|
||||
}
|
||||
}
|
||||
declare namespace ts {
|
||||
|
|
Loading…
Reference in a new issue