import { AutoWire , BaseConfiguration , Logger , MavenProfilesMap } from "@vmware/vrdt-common" ; import * as server from "vscode-languageserver" ; import { MavenProfileWatcher } from "../maven" ; import { ConfigurationWatcher } from "./ConfigurationWatcher" ; import { Initializer } from "./Initializer" ; @ AutoWire export class Settings extends BaseConfiguration { constructor ( configWatcher , profilesWatcher , initializer ) { super ( ) ; configWatcher . onDidChangeConfiguration ( this . onDidChangeConfiguration . bind ( this ) ) ; profilesWatcher . onDidChangeMavenProfiles ( this . onDidChangeProfiles . bind ( this ) ) ; initializer . onInitialize ( this . initialize . bind ( this ) ) ; } private initialize ( event ) { this . vrdev = event . initializationOptions ? event . initializationOptions : { } ; Logger . setup ( undefined , this . vrdev . log ) ; } private onDidChangeConfiguration ( { settings } ) { this . vrdev = settings . vrdev ; Logger . setup ( undefined , this . vrdev . log ) ; } private onDidChangeProfiles ( profiles ) { this . allProfiles = profiles ; } }