Exploring a Class Structure:
export class LayerEditor {
public layerManager: LayerManager;
public commandManager: CommandManager;
public tools: EditorTools;
constructor() {
this.commandManager = new CommandManager();
this.layerManager = new LayerManager(reonMap);
}
}
class LayerManager {
constructor() {}
selectLayer() {
// How can we access 'this.commandManager' from here?
}
}
In the given class structure, there is an editor class with a nested layerManager. Is there a way to reach 'this.commandManager' from inside 'LayerManager.selectLayer()'?