Options
All
  • Public
  • Public/Protected
  • All
Menu

Interface TreeDecoratorService

The TreeDecoratorService manages a set of known {link TreeDecorator}s and emits events when any of the known decorators has changes. Typically, a TreeDecoratorService provides a contribution point that can be used to register TreeDecorators exclusively for this service.

Example usage

export const MyTreeDecorator = Symbol('MyTreeDecorator');

@injectable()
export class MyDecorationService extends AbstractTreeDecoratorService {
    constructor(@inject(ContributionProvider) @named(MyTreeDecorator) protected readonly contributions: ContributionProvider<TreeDecorator>) {
        super(contributions.getContributions());
    }
}

Hierarchy

Index

Properties

Readonly onDidChangeDecorations

onDidChangeDecorations: Event<void>

Fired when any of the available tree decorators has changes.

Methods

deflateDecorators

  • deflateDecorators(decorations: Map<string, Data[]>): object
  • Transforms the decoration data into an object, so that it can be safely serialized into JSON.

    Parameters

    • decorations: Map<string, Data[]>

      the decoration data that should be deflated

    Returns object

    the decoration data as serializable JSON object

dispose

  • dispose(): void

getDecorations

inflateDecorators

  • inflateDecorators(state: any): Map<string, Data[]>