org.apache.camel.dataformat.bindy.annotation
Annotation Type DataField


@Documented
@Retention(value=RUNTIME)
public @interface DataField

An annotation used to identify in a POJO which property is link to a field of a record (csv, ...). The pos (mandatory) identifies the position of the data in the record The name is optional and could be used in the future to bind a property which a different name The pattern (optional) allows to define the pattern of the data (useful for Date, ...) The length (optional) allows to define for fixed length message the size of the data's block The precision(optional) reflects the precision to be used with BigDecimal number The position (optional) identify the position of the field in the CSV generated The required (optional) property identifies a field which is mandatory.


Required Element Summary
 int pos
          position of the data in the record (mandatory)
 
Optional Element Summary
 int length
          length of the data block (useful for the fixedlength record) (optional in this version)
 String name
          name of the field (optional)
 String pattern
          pattern that the formater will use to transform the data (optional)
 int position
          Position of the field in the message generated
 int precision
          precision of the BigDecimal number to be created
 boolean required
          Indicates if the field is mandatory
 

Element Detail

pos

public abstract int pos
position of the data in the record (mandatory)

Returns:
int

name

public abstract String name
name of the field (optional)

Returns:
String
Default:
""

pattern

public abstract String pattern
pattern that the formater will use to transform the data (optional)

Returns:
String
Default:
""

length

public abstract int length
length of the data block (useful for the fixedlength record) (optional in this version)

Returns:
int
Default:
0

precision

public abstract int precision
precision of the BigDecimal number to be created

Returns:
int
Default:
0

position

public abstract int position
Position of the field in the message generated

Returns:
int
Default:
0

required

public abstract boolean required
Indicates if the field is mandatory

Returns:
boolean
Default:
false


Apache CAMEL