|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object ix.iview.DomainEditor
public class DomainEditor
An editor/viewer frame for domain details. The editor can be created with a mandatory mode (true for simple, false for advanced) and an optional domain or an optional title. Most of the window buidling goes on in the ConstructFramePanels and their ConstructEditorPanels, except for the menubar and the toolbar.
Super-class JFrameMT defines useful menu/toolbar making things. Most of the action processing goes on in the ConstructFramePanels, except for domain specific things (read...) and window things (toggles).
Example for using DomainEditor:
...
File modelDirectory = DomainParser.getLibraryDirectory();
boolean isSimple = false;
DomainEditor frame = new DomainEditor(isSimple);
frame.setModelDirectory(modelDirectory);
frame.setVisible(true);
...
Field Summary | |
---|---|
protected IXAgent |
agent
|
DomainEditorFrame |
deFrame
|
java.io.File |
directory
|
protected JPropertiesManager |
propMan
|
UIDomain |
uiDomain
The current domain in the editor. |
Fields inherited from interface ix.iview.IDESymbols |
---|
C_ALL, C_CONDITIONS_ONLY, C_CONDITIONS_OTHER, C_NONE, C_ORDER_CONDITIONS, C_ORDER_ONLY, C_ORDER_OTHER, C_OTHER_ONLY, MODE_ADVANCED, MODE_SIMPLE, VIEW_COMPREHENSIVE, VIEW_GRAPHICAL, VIEW_MINIMAL, VIEWS |
Constructor Summary | |
---|---|
DomainEditor()
Makes the editor with the default (simple) mode. |
|
DomainEditor(boolean standAlone)
Makes the editor with the given stand alone mode. |
|
DomainEditor(boolean isSimple,
boolean standAlone)
Makes the editor with the given mode and the given stand-alone or not. |
|
DomainEditor(Domain domain)
Makes the editor with the given domain - simple, stand-alone by default. |
|
DomainEditor(Domain domain,
boolean standAlone)
Makes the editor with the given mode and load the given domain. |
|
DomainEditor(IXAgent theAgent,
Domain domain)
Makes the editor with the given domain in not-stand-alone mode. |
Method Summary | |
---|---|
protected JPropertiesManager |
ensureProperties()
|
protected JPropertiesManager |
ensurePropertiesManager()
|
Domain |
getDomain()
|
javax.swing.JFrame |
getFrame()
|
java.io.File |
getModelDirectory()
|
java.lang.String |
getName()
Needed for PropertiesApplication |
java.lang.String |
getProperty(java.lang.String which)
Gets the current setting of the given property from the application. |
UIDomain |
getUIDomain()
|
static void |
main(java.lang.String[] args)
|
void |
propertyChange(java.beans.PropertyChangeEvent evt)
|
protected static void |
readDomain(Domain domain)
|
static void |
readDomain(Domain domain,
java.lang.String resourceName)
Adds definitions from a given resource to a given domain. |
void |
refinementAdded(RefinementEvent e)
|
static java.net.URL |
resolveDomainFile(java.lang.String resourceName)
|
void |
saveExpansion(Refinement data)
The name of this is a hangover from something Jeff did. |
void |
setConstruct(IXObject construct)
Sets the given construct as the current one and displays it for editing. |
void |
setDomain(Domain domain)
Sets the given domain as current in te uiDomain. |
void |
setEditable(boolean editable)
Changes the flat that toggles I-DE viewer-only/viewer-editor mode. |
void |
setModelDirectory(java.io.File directory)
Sets the directory used to load/save models. |
void |
setProperty(java.lang.String key,
java.lang.String newValue)
Sets the given property to the given value within the application |
void |
setUIConstruct(UIObject construct)
Sets the given UIObject as the current one and displays it for editing. |
void |
setUIDomain(UIDomain uiDomain)
Sets the given UIDomain as current both in this frame and the domain editor panel. |
void |
setVisible(boolean visible)
|
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
protected IXAgent agent
public DomainEditorFrame deFrame
protected JPropertiesManager propMan
public java.io.File directory
public UIDomain uiDomain
Constructor Detail |
---|
public DomainEditor()
public DomainEditor(boolean isSimple, boolean standAlone)
isSimple
- mode: true for simple, false for advancedstandAlone
- mode: true for standAlone, false for part of other
applicationpublic DomainEditor(boolean standAlone)
standAlone
- mode: true for standAlone, false for part of other
applicationpublic DomainEditor(Domain domain)
domain
- the domain to use in the editorpublic DomainEditor(Domain domain, boolean standAlone)
domain
- the domain to use in the editorstandAlone
- mode: true for standAlone, false for part of other
applicationpublic DomainEditor(IXAgent theAgent, Domain domain)
theAgent
- the IXAgent that wants the editor to startdomain
- the domain to use in the editorMethod Detail |
---|
public java.lang.String getName()
getName
in interface PropertiesApplication
public javax.swing.JFrame getFrame()
getFrame
in interface PropertiesApplication
public java.lang.String getProperty(java.lang.String which)
PropertiesApplication
getProperty
in interface PropertiesApplication
public void setProperty(java.lang.String key, java.lang.String newValue)
setProperty
in interface PropertiesApplication
public void setEditable(boolean editable)
public void setModelDirectory(java.io.File directory)
public java.io.File getModelDirectory()
public void saveExpansion(Refinement data)
saveExpansion
in interface InternalDomainEditor
public void setConstruct(IXObject construct)
construct
- the original domain object to be viewed/editedpublic void setUIConstruct(UIObject construct)
construct
- the UI object to be viewed/editedpublic void setDomain(Domain domain)
domain
- the domain to usepublic void setUIDomain(UIDomain uiDomain)
uiDomain
- the UIDomain to usepublic UIDomain getUIDomain()
public Domain getDomain()
public void refinementAdded(RefinementEvent e)
refinementAdded
in interface DomainListener
public void propertyChange(java.beans.PropertyChangeEvent evt)
propertyChange
in interface java.beans.PropertyChangeListener
protected JPropertiesManager ensurePropertiesManager()
protected JPropertiesManager ensureProperties()
public void setVisible(boolean visible)
setVisible
in interface InternalDomainEditor
public static void main(java.lang.String[] args)
protected static void readDomain(Domain domain)
public static void readDomain(Domain domain, java.lang.String resourceName)
public static java.net.URL resolveDomainFile(java.lang.String resourceName)
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |