org.pm4j.core.pm
Interface PmDataInput

All Superinterfaces:
java.lang.Comparable<PmObject>, PmObject
All Known Subinterfaces:
PmAttr<T>, PmAttrBigDecimal, PmAttrBoolean, PmAttrDate, PmAttrDouble, PmAttrEnum<T_ENUM>, PmAttrInteger, PmAttrList<T>, PmAttrLong, PmAttrNumber<T>, PmAttrPmList<T_ITEM_PM>, PmAttrPmRef<T_REFED_PM>, PmAttrShort, PmAttrString, PmBean<T_BEAN>, PmConversation, PmElement, PmTable<T_ROW_OBJ>, PmTable.WithPager<T_ROW_ELEMENT>, PmTableRowPm, PmTabSet
All Known Implementing Classes:
PmAttrBase, PmAttrBigDecimalImpl, PmAttrBooleanImpl, PmAttrDateBase, PmAttrDateBase.WithFormatTooltip, PmAttrDateImpl, PmAttrDoubleImpl, PmAttrEnumImpl, PmAttrImpl, PmAttrIntegerImpl, PmAttrListImpl, PmAttrListImpl.PmAttrListOfIntegers, PmAttrListImpl.PmAttrListOfLongs, PmAttrListImpl.PmAttrListOfStrings, PmAttrLongImpl, PmAttrNumBase, PmAttrPmListImpl, PmAttrPmRefImpl, PmAttrShortImpl, PmAttrStringImpl, PmBeanBase, PmBeanBase.Nested, PmConversationImpl, PmConversationImpl.ChildSession, PmDataInputBase, PmElementBase, PmElementImpl, PmPagerImpl, PmPagerImpl.SelectableItemPm, PmTableColImpl.SortOrderAttr, PmTableImpl, PmTabSetImpl

public interface PmDataInput
extends PmObject

Interface for data input related presentation models.

Author:
olaf boede

Field Summary
 
Fields inherited from interface org.pm4j.core.pm.PmObject
STYLE_CLASS_DISABLED, STYLE_CLASS_ERROR, STYLE_CLASS_INFO, STYLE_CLASS_REQUIRED, STYLE_CLASS_WARN
 
Method Summary
 void commitBufferedPmChanges()
          Commits all changed values to the data store behind the presentation model.
 boolean isBufferedPmValueMode()
           
 boolean isPmValueChanged()
          Indicates a value change.
 void pmValidate()
          Validates this PM.
Generates error messages in case of validation problems.
Fires PmEvent.VALIDATION_STATE_CHANGE events in case of a change of the valid-state.
 void resetPmValues()
          Resets the values of editable attributes to their default value.
 void rollbackBufferedPmChanges()
          Clears all uncommitted changes.
 
Methods inherited from interface org.pm4j.core.pm.PmObject
accept, canSetPmTitle, compareTo, getPmConversation, getPmIconPath, getPmName, getPmParent, getPmProperty, getPmRelativeName, getPmShortTitle, getPmStyleClasses, getPmTitle, getPmTooltip, isPmEnabled, isPmReadonly, isPmValid, isPmVisible, setPmEnabled, setPmParent, setPmProperty, setPmTitle, setPmVisible
 

Method Detail

isPmValueChanged

boolean isPmValueChanged()
Indicates a value change. E.g. a value was entered, but not yet saved by the user.

The changed state usually gets cleared on execution of a PmCommand that required valid values.

Returns:
true if the value of this PM or one of its composite children was changed.

resetPmValues

void resetPmValues()
Resets the values of editable attributes to their default value.


isBufferedPmValueMode

boolean isBufferedPmValueMode()
Returns:
true when each pm value modification will be applied to an edit buffer only. Changed values will be applied when commitBufferedPmChanges() is called.

commitBufferedPmChanges

void commitBufferedPmChanges()
Commits all changed values to the data store behind the presentation model.


rollbackBufferedPmChanges

void rollbackBufferedPmChanges()
Clears all uncommitted changes.

Does not change values of the data store behind the presentation model.


pmValidate

void pmValidate()
Validates this PM.
Generates error messages in case of validation problems.
Fires PmEvent.VALIDATION_STATE_CHANGE events in case of a change of the valid-state.