public abstract class Variable extends java.lang.Object implements VariableIF
VariableIF.ACCESS_MODE, VariableIF.ACCESS_USER_TYPES| Modifier and Type | Field and Description |
|---|---|
protected boolean |
changed |
| Constructor and Description |
|---|
Variable(org.w3c.dom.Element var)
This constructor receives the element described by this GUI component.
|
| Modifier and Type | Method and Description |
|---|---|
void |
addAdoptListener(AdoptListener listener)
add an adopt callback
|
java.lang.String |
getComment()
Get the comment belongs to varaibale.
|
java.lang.String |
getCurrentValue()
Get the current string value.
|
javax.swing.JComponent |
getDefaultComponent()
Get the component to let the user set the default.
|
protected java.lang.String |
getDefaultValue()
Get the default value.
|
java.lang.String |
getDescription()
Get the description of the variable.
|
java.lang.String |
getElementValue()
GetElement value.
|
abstract javax.swing.JComponent |
getInput()
Get the input component of the variable.
|
javax.swing.JComponent |
getLabel()
This method returns the label component of the variable.
|
javax.swing.JComponent |
getResetComponent()
Get the component to let the user reset the value.
|
org.w3c.dom.Element |
getVariable()
Get the variable describing this class.
|
boolean |
hasAccessRight(VariableIF.ACCESS_MODE accessMode,
VariableIF.ACCESS_USER_TYPES accessUserType)
Checks the access right for the given user_type and access mode
|
boolean |
isChanged()
Return a boolean whether the changed the variable value.
|
boolean |
isDefault()
Has this varibnale the default value.
|
boolean |
isEnvironment()
Return a boolean whether the variable must be defined in environment.
|
boolean |
isGlobal()
Return a boolean whether the variable is global in ini file.
|
boolean |
isIniFile()
Return a boolean whether the variable must be defined in INI file.
|
boolean |
isKernel()
Is this varibale defined in kernel section.
|
boolean |
isObligatory()
Is the variable obligatory.
|
protected boolean |
isThereADefault()
Get a boolean when a default is available.
|
static boolean |
isVarEnvironment(org.w3c.dom.Element variable)
Return a boolean whether the variable must be defined in environment.
|
static boolean |
isVarGlobal(org.w3c.dom.Element variable)
Return a boolean whether the variable is global in ini file.
|
boolean |
isVarIniFile(org.w3c.dom.Element variable)
Return a boolean whether the variable must be defined in INI file.
|
void |
removeAdoptListener(AdoptListener listener)
Remove an adopt callback
|
void |
removeComment()
Remove the comment belongs to variable.
|
void |
reset()
Reset all settings to the attribute value string.
|
void |
setChanged(boolean flag)
Set the boolean whether the changed the variable value.
|
void |
setComment(java.lang.String sval)
Set the comment belongs to variable.
|
void |
setElementAccessRights(VariableIF.ACCESS_MODE mode,
VariableIF.ACCESS_USER_TYPES userType,
boolean isChecked)
Sets the new access right for given mode and user type.
|
void |
setElementToDefault()
Configure the element according to the current gui settings.
|
void |
setElementValue()
Configure the element according to the current gui settings.
|
void |
setToDefault()
Set all settings of this variable to the default.
|
abstract void |
setValue(java.lang.String def)
Set the GUI to a state that is represented by the given string.
|
java.lang.String |
toString() |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitgetValuepublic Variable(org.w3c.dom.Element var)
var - The element describes the variable.public boolean isChanged()
isChanged in interface VariableIFpublic void setChanged(boolean flag)
setChanged in interface VariableIFpublic org.w3c.dom.Element getVariable()
getVariable in interface VariableIFpublic javax.swing.JComponent getLabel()
getLabel in interface VariableIFpublic abstract javax.swing.JComponent getInput()
getInput in interface VariableIFpublic javax.swing.JComponent getDefaultComponent()
getDefaultComponent in interface VariableIFpublic javax.swing.JComponent getResetComponent()
getResetComponent in interface VariableIFprotected boolean isThereADefault()
public boolean isDefault()
isDefault in interface VariableIFpublic boolean isObligatory()
isObligatory in interface VariableIFpublic boolean isKernel()
isKernel in interface VariableIFprotected java.lang.String getDefaultValue()
public void setElementValue()
throws java.lang.Exception
setElementValue in interface VariableIFjava.lang.Exceptionpublic void setElementToDefault()
setElementToDefault in interface VariableIFpublic java.lang.String getElementValue()
public boolean isGlobal()
isGlobal in interface VariableIFpublic boolean isEnvironment()
isEnvironment in interface VariableIFpublic boolean isIniFile()
isIniFile in interface VariableIFpublic static boolean isVarGlobal(org.w3c.dom.Element variable)
public static boolean isVarEnvironment(org.w3c.dom.Element variable)
public boolean isVarIniFile(org.w3c.dom.Element variable)
public void setToDefault()
setToDefault in interface VariableIFpublic void reset()
public java.lang.String getCurrentValue()
getCurrentValue in interface VariableIFpublic java.lang.String toString()
toString in class java.lang.Objectpublic java.lang.String getDescription()
getDescription in interface VariableIFpublic java.lang.String getComment()
getComment in interface VariableIFpublic void setComment(java.lang.String sval)
setComment in interface VariableIFpublic void removeComment()
removeComment in interface VariableIFpublic abstract void setValue(java.lang.String def)
public void addAdoptListener(AdoptListener listener)
addAdoptListener in interface VariableIFpublic void removeAdoptListener(AdoptListener listener)
removeAdoptListener in interface VariableIFpublic boolean hasAccessRight(VariableIF.ACCESS_MODE accessMode, VariableIF.ACCESS_USER_TYPES accessUserType)
hasAccessRight in interface VariableIFpublic void setElementAccessRights(VariableIF.ACCESS_MODE mode, VariableIF.ACCESS_USER_TYPES userType, boolean isChecked)
setElementAccessRights in interface VariableIF