DevTools¶
Definition¶
Extends¶
Extended By¶
None
Description¶
developer tools
Method Summary¶
| Owner | Name | Return Type | Description |
|---|---|---|---|
| DevTools | findEditor(handle) | PanelEditor | Look up an already-open editor by its stable session handle. Returns null if no editor is registered for that handle. Pure lookup -- no side effect. |
| DevTools | getAddVisualizationEditor(datamodel, table) | VisualizationEditor | Return a VisualizationEditor driving the Add-Visualization dialog for the given Datamodel, pre-selecting 'table' as the source table (pass null to default to the first table). Programmatic equivalent of a datamodel's 'Add Visualization' action. Returns null if datamodel is null. |
| DevTools | getAllRenderStats() | Table | Return render stats for every panel in the session that reports them, as one table, with a Panel column saying which panel each row belongs to. Answers 'is anything on this screen failing to draw', which the per-panel call can only answer one panel at a time. This is the same table the Data Models tab of the AMI Data Statistics window shows. |
| DevTools | getCallbackEditor(owner, callbackName) | TextEditor | Return the callback editor for the given DashboardResource as a CodeEditor (getCode / setCode / lines / ...). callbackName is the callback name (e.g. 'onClick'). Any DashboardResource with AMIScript callbacks is valid -- panels, dashboards, query forms, datamodels. Call .open() to surface the UI; getCode / setCode work without surfacing. Returns null if the resource has no such callback. |
| Object | getClassName() | String | Returns the string name of this object's class type. |
| DevTools | getCodeCoverage() | CodeCoverage | Return this session's code coverage handle: which of this session's callbacks and custom methods have run, and which of their expressions. Records nothing until startup() is called on it. |
| DevTools | getCustomMethodsEditor(layoutAlias) | TextEditor | Return the Custom Methods AMIScript editor for the given layout alias. The layout-level Custom Methods script is scoped to one layout; the editor exposes its full body. Use .getCode() / .setCode() to read or mutate; call .open() to surface the UI. Returns null if the layout alias is unknown. |
| DevTools | getDataModelEditor(aliasDotName) | DatamodelEditor | Return the DataModel editor for the given DataModel identified by 'alias.name' (e.g. 'myLayout.tradesByVenue') as a AmiWebDatamodelEditor -- DM-specific introspection (getErrors / getStatus / getOutputTableNames / executeNow) plus the standard AmiWebPortletEditor lifecycle. The runtime also implements AmiWebTextEditor (the onProcess callback body); upcast for that surface. Call .open() to surface the UI. Returns null if the DataModel is unknown. |
| DevTools | getFormHtmlEditor(owner) | TextEditor | Return the Query Form HTML editor for a QueryForm panel. Valid resource types: QueryForm panels (HtmlPanel and other panel types do not have this editor). Use .getCode() / .setCode() to read or mutate the HTML; call .open() to surface the UI. Returns null if the resource is not a QueryForm. |
| DevTools | getLayoutOutline() | Table | Return the structure of the layout this session has open: one row per window, divider, panel and DataModel, carrying titles, data bindings, item counts and the AmiScript bodies each object owns. Transient windows are included. Answers 'what is this layout made of' without exporting and parsing the whole layout JSON. |
| DevTools | getOpenEditors() | List | Return all user-visible (non-admin) editors registered in this session, filtered to one entry per visible window (inactive tabs in multi-tab editors are excluded). |
| DevTools | getPanelSettingsEditor(owner) | JsonSettingsEditor | Return the JSON-settings editor for a panel. The settings-portlet hierarchy is shared across all panel types (Tree, Chart, Surface, Filter, Table, ...), but only the Tree subclass currently implements the AmiWebJsonSettingsEditor surface. Returns null for panel types whose settings editor has not been migrated yet. Use .getJson() / .setJson() to read or mutate the JSON document; call .open() to surface the UI. |
| DevTools | getRenderStats(panel) | Table | Return what a panel actually BUILT from its data, as opposed to whether its configuration is valid -- the companion to getSchemaWarnings(). One row per part: a chart reports its axes and layers separately, carrying each layer's DataModel binding, the rows it built, and a Problem cell that says outright when it built nothing. Returns null when the panel is not DataModel-bound or its kind does not report stats. |
| DevTools | getReplaceVisualizationEditor(panel, datamodel, table) | VisualizationEditor | Return a VisualizationEditor driving the 'Replace With... -> Table / Visualization / Form' wizard targeting the given panel, so its visualization can be swapped in place. (optionally pre-select a table using null -> defaults to the first). Returns null if 'panel' is not a live panel. |
| DevTools | getSchemaWarnings(panel) | List | Return the schema warnings for a DataModel-bound panel -- the same warnings shown by the panel's 'View N Schema Warning(s)' context menu item. Each entry describes a formula or column reference that does not resolve in the panel's bound DataModel output schema. Returns an empty list when the panel is not DM-bound (HTML / divider / blank), when all references are valid, or when panel is null. |
| Object | toJson() | String | Returns a string of a json representation of this object. |
Method Definitions¶
findEditor(handle)¶
PanelEditor DevTools::findEditor(String handle)
Description¶
Look up an already-open editor by its stable session handle. Returns null if no editor is registered for that handle. Pure lookup -- no side effect.
Parameter Definition¶
| Name | Type | Description |
|---|---|---|
| handle | String |
getAddVisualizationEditor(datamodel,table)¶
VisualizationEditor DevTools::getAddVisualizationEditor(Datamodel datamodel, String table)
Description¶
Return a VisualizationEditor driving the Add-Visualization dialog for the given Datamodel, pre-selecting 'table' as the source table (pass null to default to the first table). Programmatic equivalent of a datamodel's 'Add Visualization' action. Returns null if datamodel is null.
Parameter Definition¶
| Name | Type | Description |
|---|---|---|
| datamodel | Datamodel | |
| table | String |
getAllRenderStats()¶
Table DevTools::getAllRenderStats()
Description¶
Return render stats for every panel in the session that reports them, as one table, with a Panel column saying which panel each row belongs to. Answers 'is anything on this screen failing to draw', which the per-panel call can only answer one panel at a time. This is the same table the Data Models tab of the AMI Data Statistics window shows.
getCallbackEditor(owner,callbackName)¶
TextEditor DevTools::getCallbackEditor(DashboardResource owner, String callbackName)
Description¶
Return the callback editor for the given DashboardResource as a CodeEditor (getCode / setCode / lines / ...). callbackName is the callback name (e.g. 'onClick'). Any DashboardResource with AMIScript callbacks is valid -- panels, dashboards, query forms, datamodels. Call .open() to surface the UI; getCode / setCode work without surfacing. Returns null if the resource has no such callback.
Parameter Definition¶
| Name | Type | Description |
|---|---|---|
| owner | DashboardResource | |
| callbackName | String |
getClassName()¶
Description¶
Returns the string name of this object's class type.
getCodeCoverage()¶
CodeCoverage DevTools::getCodeCoverage()
Description¶
Return this session's code coverage handle: which of this session's callbacks and custom methods have run, and which of their expressions. Records nothing until startup() is called on it.
getCustomMethodsEditor(layoutAlias)¶
TextEditor DevTools::getCustomMethodsEditor(String layoutAlias)
Description¶
Return the Custom Methods AMIScript editor for the given layout alias. The layout-level Custom Methods script is scoped to one layout; the editor exposes its full body. Use .getCode() / .setCode() to read or mutate; call .open() to surface the UI. Returns null if the layout alias is unknown.
Parameter Definition¶
| Name | Type | Description |
|---|---|---|
| layoutAlias | String |
getDataModelEditor(aliasDotName)¶
DatamodelEditor DevTools::getDataModelEditor(String aliasDotName)
Description¶
Return the DataModel editor for the given DataModel identified by 'alias.name' (e.g. 'myLayout.tradesByVenue') as a AmiWebDatamodelEditor -- DM-specific introspection (getErrors / getStatus / getOutputTableNames / executeNow) plus the standard AmiWebPortletEditor lifecycle. The runtime also implements AmiWebTextEditor (the onProcess callback body); upcast for that surface. Call .open() to surface the UI. Returns null if the DataModel is unknown.
Parameter Definition¶
| Name | Type | Description |
|---|---|---|
| aliasDotName | String |
getFormHtmlEditor(owner)¶
TextEditor DevTools::getFormHtmlEditor(DashboardResource owner)
Description¶
Return the Query Form HTML editor for a QueryForm panel. Valid resource types: QueryForm panels (HtmlPanel and other panel types do not have this editor). Use .getCode() / .setCode() to read or mutate the HTML; call .open() to surface the UI. Returns null if the resource is not a QueryForm.
Parameter Definition¶
| Name | Type | Description |
|---|---|---|
| owner | DashboardResource |
getLayoutOutline()¶
Table DevTools::getLayoutOutline()
Description¶
Return the structure of the layout this session has open: one row per window, divider, panel and DataModel, carrying titles, data bindings, item counts and the AmiScript bodies each object owns. Transient windows are included. Answers 'what is this layout made of' without exporting and parsing the whole layout JSON.
getOpenEditors()¶
List DevTools::getOpenEditors()
Description¶
Return all user-visible (non-admin) editors registered in this session, filtered to one entry per visible window (inactive tabs in multi-tab editors are excluded).
getPanelSettingsEditor(owner)¶
JsonSettingsEditor DevTools::getPanelSettingsEditor(DashboardResource owner)
Description¶
Return the JSON-settings editor for a panel. The settings-portlet hierarchy is shared across all panel types (Tree, Chart, Surface, Filter, Table, ...), but only the Tree subclass currently implements the AmiWebJsonSettingsEditor surface. Returns null for panel types whose settings editor has not been migrated yet. Use .getJson() / .setJson() to read or mutate the JSON document; call .open() to surface the UI.
Parameter Definition¶
| Name | Type | Description |
|---|---|---|
| owner | DashboardResource |
getRenderStats(panel)¶
Table DevTools::getRenderStats(DashboardResource panel)
Description¶
Return what a panel actually BUILT from its data, as opposed to whether its configuration is valid -- the companion to getSchemaWarnings(). One row per part: a chart reports its axes and layers separately, carrying each layer's DataModel binding, the rows it built, and a Problem cell that says outright when it built nothing. Returns null when the panel is not DataModel-bound or its kind does not report stats.
Parameter Definition¶
| Name | Type | Description |
|---|---|---|
| panel | DashboardResource |
getReplaceVisualizationEditor(panel,datamodel,table)¶
VisualizationEditor DevTools::getReplaceVisualizationEditor(DashboardResource panel, Datamodel datamodel, String table)
Description¶
Return a VisualizationEditor driving the 'Replace With... -> Table / Visualization / Form' wizard targeting the given panel, so its visualization can be swapped in place. (optionally pre-select a table using null -> defaults to the first). Returns null if 'panel' is not a live panel.
Parameter Definition¶
| Name | Type | Description |
|---|---|---|
| panel | DashboardResource | |
| datamodel | Datamodel | |
| table | String |
getSchemaWarnings(panel)¶
List DevTools::getSchemaWarnings(DashboardResource panel)
Description¶
Return the schema warnings for a DataModel-bound panel -- the same warnings shown by the panel's 'View N Schema Warning(s)' context menu item. Each entry describes a formula or column reference that does not resolve in the panel's bound DataModel output schema. Returns an empty list when the panel is not DM-bound (HTML / divider / blank), when all references are valid, or when panel is null.
Parameter Definition¶
| Name | Type | Description |
|---|---|---|
| panel | DashboardResource |
toJson()¶
Description¶
Returns a string of a json representation of this object.