* Create a new WidgetState proto for the widget with the given ID, * overwriting any that currently exists.
(widgetId: string)
| 151 | * overwriting any that currently exists. |
| 152 | */ |
| 153 | public createState(widgetId: string): WidgetState { |
| 154 | const state = new WidgetState({ id: widgetId }) |
| 155 | this.widgetStates.set(widgetId, state) |
| 156 | return state |
| 157 | } |
| 158 | |
| 159 | /** Return the WidgetState for the given widgetID if it exists. */ |
| 160 | public getState(widgetId: string): WidgetState | undefined { |
no test coverage detected