|
JFormDesigner 5.0.4 Runtime API | ||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectcom.jformdesigner.model.FormObject
com.jformdesigner.model.FormModel
public class FormModel
A form model represents a JFormDesigner form in memory.
FormLoader
can be used to load a .jfd file and
FormSaver
to save a form model to a .jfd file.
FormCreator
can create Swing components from
a form model.
Example:
FormContainer panel = ... // see FormContainer
FormRoot root = new FormRoot();
root.add(panel);
FormModel model = new FormModel();
model.setContentType("form/swing");
model.setRoot(root);
Field Summary | |
---|---|
java.lang.String |
fileHeader
The header comment of the file or null. |
Fields inherited from class com.jformdesigner.model.FormObject |
---|
NULL_VALUE |
Constructor Summary | |
---|---|
FormModel()
Constructs a form model. |
Method Summary | |
---|---|
boolean |
accept(FormBindingVisitor visitor)
Accepts the given visitor. |
boolean |
accept(FormComponentVisitor visitor)
Accepts the given visitor. |
java.lang.ClassLoader |
getClassLoader()
Returns the class loader used to load the form model. |
java.lang.String |
getContentType()
Returns the content type of the form model. |
com.jformdesigner.model.FormModelEventProvider |
getEventProvider()
For internal use only. |
FormComponent |
getFormComponent(java.lang.String name)
Returns the form component for the specified component name. |
java.lang.String[] |
getNames()
Returns all form component names used in this form model. |
FormRoot |
getRoot()
Returns the root of this form model. |
boolean |
isUndoRecording()
For internal use only. |
void |
set_ClassLoader(java.lang.ClassLoader classLoader)
For internal use only. |
void |
set_EventProvider(com.jformdesigner.model.FormModelEventProvider eventProvider)
For internal use only. |
void |
setContentType(java.lang.String contentType)
Sets the content type of the form model. |
void |
setRoot(FormRoot root)
Sets the root of this form model. |
boolean |
setUndoRecording(boolean undoRecording)
For internal use only. |
Methods inherited from class com.jformdesigner.model.FormObject |
---|
getProperties, getProperty, getProperty, getPropertyBoolean, getPropertyBoolean, getPropertyCount, getPropertyDouble, getPropertyDouble, getPropertyInt, getPropertyInt, getPropertyNames, getPropertyString, getPropertyString, getReferenceCount, properties, propertyNames, setProperty, setProperty, setProperty, setPropertyBoolean, setPropertyBoolean, setPropertyDouble, setPropertyDouble, setPropertyInt, setPropertyInt, setPropertyString, toString |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Field Detail |
---|
public java.lang.String fileHeader
Constructor Detail |
---|
public FormModel()
Method Detail |
---|
public java.lang.ClassLoader getClassLoader()
public void set_ClassLoader(java.lang.ClassLoader classLoader)
public java.lang.String getContentType()
public void setContentType(java.lang.String contentType)
Use form/swing
for Swing forms.
public FormRoot getRoot()
public void setRoot(FormRoot root)
public FormComponent getFormComponent(java.lang.String name)
public java.lang.String[] getNames()
public boolean accept(FormComponentVisitor visitor)
FormComponentVisitor.visit(com.jformdesigner.model.FormComponent)
is called
with all form components of this form model.
visitor
- The visitor.
FormComponentVisitor.visit(com.jformdesigner.model.FormComponent)
.public boolean accept(FormBindingVisitor visitor)
FormBindingVisitor.visit(com.jformdesigner.model.FormBinding)
is called
with all form bindings of this form model.
visitor
- The visitor.
FormBindingVisitor.visit(com.jformdesigner.model.FormBinding)
.public boolean isUndoRecording()
public boolean setUndoRecording(boolean undoRecording)
public com.jformdesigner.model.FormModelEventProvider getEventProvider()
public void set_EventProvider(com.jformdesigner.model.FormModelEventProvider eventProvider)
|
JFormDesigner 5.0.4 Runtime API | ||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |