|
LEONARDI Application Composer - 8.9.0.40 by W4 S.A. | ||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectleon.control.LyController
leon.control.form.LyFieldController
leon.control.form.LyFieldConsultController
leon.control.form.LyFieldSetController
public class LyFieldSetController
Default field controller for a modification.
LySetController
Field Summary | |
---|---|
static java.lang.String |
__VERSION
File version |
static java.lang.String |
STANDARD_ARRAY_TOOL
Name of the tranverse tool like STANDARD_CLASSINFO but for internal update in an array. |
static java.lang.String |
STANDARD_CLASSINFO
Name of a standard classInfo used in creation when type of the object is dependant of an other fieldinfo (for example: a group of radio bouton, each one defining a different type so we have to create the good form when an action occurs). |
static java.lang.String |
TRANSVERSE_ACTION_SEP
Separator used for labels of transverse action tools (inserted between action name and class name). |
Fields inherited from class leon.control.form.LyFieldController |
---|
FORM_FIELD_SEP, OLD_FORM_FIELD_SEP |
Fields inherited from class leon.control.LyController |
---|
_nbControllers, _nextId, CONTROLLER_ID_SEP, DEFAULT_IMAGE_FORMAT, DEMAND_HELP, ID_SEP |
Constructor Summary | |
---|---|
LyFieldSetController(LySetController parent,
LyFieldInfo fieldInfo)
Constructor. |
Method Summary | |
---|---|
void |
actionDemand(LyActionDemand demand)
Invoked when an action occurs. |
void |
addTempFilePath(java.lang.String path)
Add a file to the delete on free list |
void |
cancel()
Method called when the form is cancelled. |
boolean |
checkIfModified()
Checks if the value for the fieldInfo has been modified. |
void |
clear()
Clears specified fieldInfo value : setting value to null. |
void |
commit()
Method called when all modifications are committed. |
void |
completeValue(java.lang.String value)
Internal method for completing a formatted value (for a unit). |
short |
control()
Controls current edition. |
short |
endValidate()
End validation of the form : commit edition. |
LyContext |
getControllerContext()
Gets the controller context. |
LyBuilder |
getDefaultBuilder()
Factory of the default builder for a controller. |
LyValue |
getFieldValue()
Extract current value for the specified fieldInfo in the form. |
LyValue |
getFieldValue(LyUnit unit)
Extract current value for the specified fieldInfo in the form. |
LyValue |
getFinalValue()
Extract final value for the specified fieldInfo in the form. |
LyValue |
getLastValue()
Gets last value of this field controller. |
LyObject |
getModel()
get the model object |
LyFieldSetController |
getParentFieldController()
|
LySetController |
getSetController()
get the associated Set controller |
LyInfoDataList<LyAction,LyClassInfo> |
getTransverseActions()
Get the transverse action associated to this field controller |
LyUnit |
getUnit()
Get current unit for the specified fieldInfo in the form. |
java.lang.Object |
getValue()
Accessor to the internal value associated to a filedInfo. |
boolean |
isCreation()
Return the mode of the controller |
boolean |
isEditable()
Accessor to the editable/ non editable status for a field in the form. |
boolean |
isEnabled()
Accessor to the enabled/disabled status for a field in the form. |
boolean |
isOptional()
Accessor to the optional status for a field in the form. |
void |
reset()
Resets specified fieldInfo value : the default value is fetched from the associated behavior. |
void |
resetFromValue(java.lang.Object value,
boolean freeOldValue,
boolean createNewValue)
Sets the field content from the specified value Any value modified by the user is the form is lost. |
boolean |
restore(LyFieldSave fieldSave)
Restore field input. |
LyFieldSave |
save(boolean full)
Save field input. |
void |
setEditable(boolean editable)
Changes current field status to (non-)editable. |
void |
setEnabled(boolean enabled)
Changes current field status to (non-)enabled. |
void |
setFieldValue(LyValue newValue,
boolean propagate)
Sets the value of a fieldInfo This methods extracts the value and calls updateFieldItem. |
void |
setHidden(boolean hidden)
Changes current field status to (non-)hidden. |
void |
setInternal(boolean status)
Identify this controller as being hidden. |
void |
setOptional(boolean optional)
Changes current field status to (non-)optional. |
short |
startValidate()
Start validation of the form. |
void |
unitChanged(java.lang.String newUnitId,
java.lang.String oldUnitId)
Internal method for propagating a unit change. |
void |
update(LyFieldInfo origin,
boolean propagate,
boolean valueChange)
Utility method (internal use for behavior) to calculate formulas of fieldInfos. |
void |
updateFieldItem(java.lang.Object newValue,
java.lang.Object oldValue,
boolean propagate)
Internal use : update the value of a fieldInfo in the form. |
void |
updateViewContent()
Check (when it makes sence) the graphical component to see if they have a pending value typed by the user, and not yet refreshed in the LyView components. |
void |
updateViewFromValues(LyDemand demand)
Update the view of the controller with the specified values from the demand. |
Methods inherited from class leon.control.form.LyFieldConsultController |
---|
isHidden, propagate, setLabel |
Methods inherited from class leon.control.form.LyFieldController |
---|
clearViewCache, free, getAction, getAreaController, getBehavior, getClassInfo, getComponent, getDefaultFieldUnit, getDefaultFieldUnit, getEnvironment, getFieldController, getFieldInfo, getFormController, getFormField, getFormField, getImage, getInfoLabel, getInfoLabel, getLabel, getObject, getState, getViewController, hasMark, invokeTransverseAction, isIdle, menuDemand, setAreaNoScroll, setFieldValue, setFormField, setState, toString |
Methods inherited from class leon.control.LyController |
---|
activateViewDemand, demandPerformed, dragDropDemand, getApplication, getBehaviorInterface, getBuilder, getClassInfo, getId, getImage, getImage, getImage, getImageFromPrefix, getImageFromPrefix, getImageFromPrefix, getKeyValue, getLastModified, getName, getObjectId, getParent, getSession, getUserData, getView, getViewManager, hasViewController, helpDemand, hideView, hideView, isFreed, selectionDemand, setBuilder, setBuilderClass, setIdle, setLastModified, setName, setUserData, showError, showError, showView, showWarning |
Methods inherited from class java.lang.Object |
---|
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Field Detail |
---|
public static final java.lang.String __VERSION
public static final java.lang.String STANDARD_CLASSINFO
public static final java.lang.String STANDARD_ARRAY_TOOL
public static final java.lang.String TRANSVERSE_ACTION_SEP
Constructor Detail |
---|
public LyFieldSetController(LySetController parent, LyFieldInfo fieldInfo)
parent
- parent controllerfieldInfo
- fieldInfo handled by this controllerMethod Detail |
---|
public LyBuilder getDefaultBuilder()
LyController
getDefaultBuilder
in class LyFieldConsultController
LyFieldConsultController.getDefaultBuilder()
public LyInfoDataList<LyAction,LyClassInfo> getTransverseActions()
getTransverseActions
in class LyFieldConsultController
public boolean isCreation()
public LyObject getModel()
public LySetController getSetController()
public void updateViewFromValues(LyDemand demand)
updateViewFromValues
in class LyController
demand
- demand parameters sent by the view component.updateViewContent()
public void updateViewContent()
public void actionDemand(LyActionDemand demand)
actionDemand
in class LyFieldController
demand
- the action demandLyController.demandPerformed(leon.view.event.LyDemand)
public void setFieldValue(LyValue newValue, boolean propagate)
setFieldValue
in class LyFieldController
newValue
- the new value of the field. This value may be null to set the value to blank
(empty).propagate
- Indicates whether the change is notified (propagated) to other fields or
not. This is useless if you reset all fields for instance.getFieldValue()
public LyUnit getUnit()
public LyValue getFinalValue()
public LyValue getFieldValue()
getFieldValue
in class LyFieldConsultController
public LyValue getFieldValue(LyUnit unit)
unit
- Unit of the value.
public void updateFieldItem(java.lang.Object newValue, java.lang.Object oldValue, boolean propagate)
updateFieldItem
in class LyFieldConsultController
newValue
- the new value of the field. This value may be null, a LyValue instance or
the internal value associated to thge fieldInfo. See LyValue.getValue()oldValue
- the latest value of the field. This value may be null, a LyValue instance or
the internal value associated to thge fieldInfo. See LyValue.getValue()propagate
- Indicates whether the change is notified (propagated) to other fields or
not. This is useless if you reset all fields for instance.setFieldValue(leon.data.LyValue, boolean)
public void completeValue(java.lang.String value)
value
- the current fieldValue (not completed).public void unitChanged(java.lang.String newUnitId, java.lang.String oldUnitId)
The LySetController additionaly impact the view using the setValid method.
newUnitId
- The new fieldinfo unit.oldUnitId
- The old fieldinfo unit.public short startValidate()
LyFormInterface
public short endValidate()
LyFormInterface
public void commit()
public void cancel()
public java.lang.Object getValue()
public void clear()
public void reset()
public void update(LyFieldInfo origin, boolean propagate, boolean valueChange)
update
in class LyFieldConsultController
origin
- the field that propagates the modificationpropagate
- Indicates whether the change is notified (propagated) to other fields or
not.valueChange
- indicates if thie event occurs after a value changedsetFieldValue(leon.data.LyValue, boolean)
public void setOptional(boolean optional)
optional
- new fieldInfo status. (default is from the view description)public boolean isOptional()
public void setEditable(boolean editable)
editable
- new fieldInfo status. (default is true or obtained from the view
description)public boolean isEditable()
public void setEnabled(boolean enabled)
enabled
- new fieldInfo status. (default is true or obtained from the view
description)public boolean isEnabled()
public void setHidden(boolean hidden)
setHidden
in class LyFieldConsultController
hidden
- new fieldInfo visibility. (default is true)public final LyValue getLastValue()
public boolean checkIfModified()
public LyContext getControllerContext()
getControllerContext
in interface LyControllerContextInterface
LyControllerContextInterface.getControllerContext()
public short control()
public void setInternal(boolean status)
status
- the internal statuspublic void resetFromValue(java.lang.Object value, boolean freeOldValue, boolean createNewValue)
resetFromValue
in class LyFieldController
value
- new value to set in the field.freeOldValue
- indicates if the old value should be freed (deleted) when it is an
objectcreateNewValue
- indicates if a new empty value should created when object is null and
when the value is an objectpublic void addTempFilePath(java.lang.String path)
path
- the file path to add to the delete listpublic LyFieldSave save(boolean full)
save
in class LyFieldController
public boolean restore(LyFieldSave fieldSave)
restore
in class LyFieldController
public final LyFieldSetController getParentFieldController()
|
(c) January 2013 - W4 S.A. | ||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |