public interface FieldProcessor
FieldProcessor keeps track of the MetaData and Linkpanels defined in the
DataConfig of a Datasource. It provides several methods
to add Messages, which can be field-specific.| Modifier and Type | Method and Description |
|---|---|
void |
addErrorMessage(FieldDef field,
String message)
Adds a
Message of type MessageType.ERROR to the
given field. |
void |
addErrorMessage(String message)
Adds a
Message of type MessageType.ERROR. |
void |
addInvalidMessage(FieldDef field,
String message)
Adds a
Message of type MessageType.INVALID to the
given field. |
void |
addInvalidMessage(String message)
Adds a
Message of type MessageType.INVALID. |
void |
addLinkPanels(List<Linkpanel> panels)
Adds the given list of
Linkpanels to this FieldProcessor |
void |
addNoticeMessage(FieldDef field,
String message)
Adds a
Message of type MessageType.NOTICE to the
given field. |
void |
addNoticeMessage(String message)
Adds a
Message of type MessageType.INVALID. |
void |
addOkMessage(FieldDef field,
String message)
Adds a
Message of type MessageType.OK to the given
field. |
void |
addOkMessage(String message)
Adds a
Message of type MessageType.OK. |
void |
clearFieldMessages()
Clears all
Messages which were previously added using
addXXMessage(FieldDef field, String message). |
void |
clearFieldMessages(String... fieldBindings)
|
void |
clearMessages()
Clears all
Messages which were previously added using
addXXMessage(String message). |
FieldDef |
getField(String fieldBinding)
Returns the
FieldDef with the given binding, if existing. |
List<FieldDef> |
getFields()
Returns all
FieldDefintions known by this FieldProcessor. |
Linkpanel |
getLinkPanel(String fieldName)
Returns the
Linkpanel with the given name, if existing. |
Messages |
getMessages()
|
MetaData |
getMetaData()
Returns the
MetaData of this FieldProcessor. |
org.springframework.data.domain.Pageable |
getPageable()
Returns the
Pageable for this FieldProcessor. |
String |
getReference()
|
boolean |
hasErrors()
|
boolean |
hasField(String fieldBinding)
Checks whether a
FieldDef with the given binding exists for this FieldProcessor. |
boolean |
hasFieldErrors()
Checks whether one of the fields has a
Message of type
MessageType.ERROR. |
List<FieldDef> getFields()
FieldDefintions known by this FieldProcessor.FieldDef getField(String fieldBinding)
FieldDef with the given binding, if existing.fieldBinding - the binding of the FieldDef to returnFieldDef with the given binding, or null if no such FieldDef existsFieldDef.getBinding()MetaData getMetaData()
MetaData of this FieldProcessor.MetaDataboolean hasField(String fieldBinding)
FieldDef with the given binding exists for this FieldProcessor.fieldBinding - the binding of the FieldDef to checktrue if such a FieldDef exists, false otherwise.getField(String)String getReference()
boolean hasErrors()
true if there are any Messages of
MessageType.ERROR, false otherwiseaddErrorMessage(String),
addErrorMessage(FieldDef, String)boolean hasFieldErrors()
Message of type
MessageType.ERROR.true if any of the FieldProcessors FieldDefs has a
Message of type MessageType.ERROR,
false otherwiseaddErrorMessage(FieldDef, String)void addOkMessage(String message)
Message of type MessageType.OK.message - the message to addvoid addLinkPanels(List<Linkpanel> panels)
Linkpanels to this FieldProcessorpanels - a list of LinkpanelsLinkpanel getLinkPanel(String fieldName)
Linkpanel with the given name, if existing.void addOkMessage(FieldDef field, String message)
Message of type MessageType.OK to the given
field.void addErrorMessage(String message)
Message of type MessageType.ERROR.message - the message to addhasErrors()void addErrorMessage(FieldDef field, String message)
Message of type MessageType.ERROR to the
given field.field - the FieldDef to add the Message tomessage - the message to addhasErrors(),
hasFieldErrors()void addInvalidMessage(String message)
Message of type MessageType.INVALID.message - the message to addvoid addInvalidMessage(FieldDef field, String message)
Message of type MessageType.INVALID to the
given field.void addNoticeMessage(String message)
Message of type MessageType.INVALID.message - the message to addvoid addNoticeMessage(FieldDef field, String message)
Message of type MessageType.NOTICE to the
given field.Messages getMessages()
Messages-object containing all Messages previously added
using addXXMessage(String message).Messages instance containing the previously added MessagesaddOkMessage(String),
addNoticeMessage(String),
addInvalidMessage(String),
addErrorMessage(String)void clearMessages()
Messages which were previously added using
addXXMessage(String message).void clearFieldMessages()
Messages which were previously added using
addXXMessage(FieldDef field, String message).void clearFieldMessages(String... fieldBindings)
fieldBindings - the bindings of the fields to clear the messages foraddOkMessage(FieldDef, String),
addNoticeMessage(FieldDef, String),
addInvalidMessage(FieldDef, String),
addErrorMessage(FieldDef, String),
FieldDef.getBinding()org.springframework.data.domain.Pageable getPageable()
Pageable for this FieldProcessor.PageableCopyright © 2011–2023 aiticon GmbH. All rights reserved.