Module: explorer/widgets/editorarea/EditorArea

explorer/widgets/editorarea/EditorArea

Extends

  • dijit/_WidgetBase
  • dijit/_TemplatedMixin
  • dijit/_WidgetsInTemplateMixin
  • dojo/Evented

Requires

Methods

addToUi(data)

Adds a spec's tabs to the Ui and adjusts the render button according to the type of spec.
Parameters:
Name Type Description
data Object Data of the spec.
Source:

createTab(resource, editorTabs, isActive, editor)

Creates an EditorTab of a spec.
Parameters:
Name Type Description
resource Object An object that contains data about a spec's particular resource (e.g. jsResource).
editorTabs EditorTabs Contains each EditorTab of the spec.
isActive Boolean Whether or not the tab is the focused tab.
editor GadgetEditor the Editor corresponding to the tab's resource (e.g. JSEditor).
Source:

createTabsAndEditors(data, editorTabs)

Creates the necessary EditorTabs and Editors for a spec.
Parameters:
Name Type Description
data Object Data of the spec.
editorTabs EditorTabs Contains each EditorTab of the spec.
Source:

destroy()

Destroys this instance of EditorArea.
Source:

displaySpec(id)

Displays the spec's code - resets the tabs and adds the necessary tabs and editors to the Ui.
Parameters:
Name Type Description
id String The ID of the spec to display
Source:

getContextRoot() → {String}

Gets the context root.
Source:
Returns:
The context root.
Type
String

getEditorTabs() → {EditorTabs}

Getter method for EditorTabs.
Source:
Returns:
The EditorTabs object.
Type
EditorTabs

getGadgetSpec() → {Object}

Gets the GadgetSpec object.
Source:
Returns:
The GadgetSpec object.
Type
Object

getGadgetSpecService() → {gadgetSpecService}

Getter method for the GadgetSpecService module for testing purposes.
Source:
Returns:
The gadgetSpecService object.
Type
gadgetSpecService

postGadgetSpec(thenFunction)

Posts a spec to the servlet. This method is used when rerendering a spec.
Parameters:
Name Type Description
thenFunction Function Callback function to execute if the POST to the servlet is successful.
Source:

setTitle(title)

Sets the title of a spec in the Ui.
Parameters:
Name Type Description
title String Title of the spec.
Source:

startup()

Called right after widget is added to the dom. See link for more information.
Source:
See: