Class ValueAcceptanceCriteria
java.lang.Object
de.xima.fc.interfaces.workflow.value.ValueAcceptanceCriteria
Factory for creating
IValueAcceptanceCriteria instances.- Since:
- 8.5.0
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic final classBuilder for custom value acceptance criteria. -
Method Summary
Modifier and TypeMethodDescriptionstatic IValueAcceptanceCriteriaGets a value acceptance criteria instance that accepts superfluous data, so that an invalid value can be made valid by dropping the superfluous data.Returns a builder prepopulated with the data fromacceptSuperfluousData().builder()Creates a new builder for custom value acceptance criteria.builder(IValueAcceptanceCriteria criteria) Creates a new builder for custom value acceptance criteria, pre-initialized with the values from the given criteria.static IValueAcceptanceCriteriastrict()Returns an instance that represents the strictest possible acceptance criteria, such as not allowing extraneous fields or elements and enforcing all defined ranges.Returns a builder prepopulated with the data fromstrict().
-
Method Details
-
acceptSuperfluousData
Gets a value acceptance criteria instance that accepts superfluous data, so that an invalid value can be made valid by dropping the superfluous data. In other words, the existing data must match the constraints, but additional data is allowed. For example, allows extraneous fields in records and extraneous elements in tuples, or strings that are longer (but not shorter!) than the maximum allowed length.- Returns:
- A value acceptance criteria that accepts superfluous data.
-
acceptSuperfluousDataBuilder
Returns a builder prepopulated with the data fromacceptSuperfluousData().- Returns:
- A strict acceptance criteria builder.
-
builder
Creates a new builder for custom value acceptance criteria, pre-initialized with the values from the given criteria.- Parameters:
criteria- The criteria to copy values from.- Returns:
- A new builder.
-
builder
Creates a new builder for custom value acceptance criteria. All values are initialized to the strictest possible acceptance criteria, i.e. the same asstrict().- Returns:
- A new builder.
-
strict
Returns an instance that represents the strictest possible acceptance criteria, such as not allowing extraneous fields or elements and enforcing all defined ranges.- Returns:
- A strict acceptance criteria.
-
strictBuilder
Returns a builder prepopulated with the data fromstrict().- Returns:
- A strict acceptance criteria builder.
-