Package org.beanio.builder
Class SegmentBuilderSupport<T extends SegmentBuilderSupport<T>>
- java.lang.Object
-
- org.beanio.builder.PropertyBuilderSupport<T>
-
- org.beanio.builder.SegmentBuilderSupport<T>
-
- Direct Known Subclasses:
RecordBuilder
,SegmentBuilder
public abstract class SegmentBuilderSupport<T extends SegmentBuilderSupport<T>> extends PropertyBuilderSupport<T>
Support for segment configuration builders.- Since:
- 2.1.0
-
-
Method Summary
All Methods Instance Methods Abstract Methods Concrete Methods Modifier and Type Method Description T
addField(FieldBuilder field)
Adds a field to this component.T
addSegment(SegmentBuilder segment)
Adds a segment to this component.protected abstract SegmentConfig
getConfig()
Returns the configuration settings.T
key(java.lang.String name)
Sets the name of a child component to use as the key for an inline map bound to this record or segment.T
value(java.lang.String name)
Sets the name of a child component to return as the value for this record or segment in lieu of a bound class.-
Methods inherited from class org.beanio.builder.PropertyBuilderSupport
collection, getter, lazy, maxOccurs, me, minOccurs, occurs, occurs, setter, type, xmlName, xmlNamespace, xmlPrefix, xmlType
-
-
-
-
Method Detail
-
getConfig
protected abstract SegmentConfig getConfig()
Description copied from class:PropertyBuilderSupport
Returns the configuration settings.- Specified by:
getConfig
in classPropertyBuilderSupport<T extends SegmentBuilderSupport<T>>
- Returns:
- the configuration
-
key
public T key(java.lang.String name)
Sets the name of a child component to use as the key for an inline map bound to this record or segment.- Parameters:
name
- the component name- Returns:
- this
-
value
public T value(java.lang.String name)
Sets the name of a child component to return as the value for this record or segment in lieu of a bound class.- Parameters:
name
- the component name- Returns:
- this
-
addSegment
public T addSegment(SegmentBuilder segment)
Adds a segment to this component.- Parameters:
segment
- the segment to add- Returns:
- this
-
addField
public T addField(FieldBuilder field)
Adds a field to this component.- Parameters:
field
- the field to add- Returns:
- this
-
-