Interface ICodeEditorOpener

Expand description

Represents an object that can handle editor open operations (e.g. when "go to definition" is called with a resource other than the current model).

interface ICodeEditorOpener {
    openCodeEditor(
        source: ICodeEditor,
        resource: Uri,
        selectionOrPosition?: IPosition | IRange,
    ): boolean | Promise<boolean>;
}

Methods§

§

openCodeEditor(
    source: ICodeEditor,
    resource: Uri,
    selectionOrPosition?: IPosition | IRange,
): boolean | Promise<boolean>

Callback that is invoked when a resource other than the current model should be opened (e.g. when "go to definition" is called). The callback should return true if the request was handled and false otherwise.