com.univocity.parsers.annotations
Annotation Type Headers


@Retention(value=RUNTIME)
@Inherited
@Target(value={TYPE,ANNOTATION_TYPE})
public @interface Headers

The Headers annotation allows java beans to configure how to handle field names in a given input/output

With this annotation, you can configure the sequence of headers to use when reading/writing:

This annotation has no effect if CommonSettings.isAutoConfigurationEnabled() evaluates to false.

Author:
uniVocity Software Pty Ltd - parsers@univocity.com
See Also:
BeanWriterProcessor, BeanProcessor

Optional Element Summary
 boolean extract
          Indicates whether the first row of on the input should be extracted as a header row.
 String[] sequence
          Returns the sequence of header names in the input/output
 boolean write
          Indicates whether a row with headers should be written to the output.
 

sequence

public abstract String[] sequence
Returns the sequence of header names in the input/output

Returns:
the sequence of header names in the input/output
Default:
{}

write

public abstract boolean write
Indicates whether a row with headers should be written to the output.

Returns:
a flag indicating whether to write the headers to the output when writing instances of a java bean.
Default:
true

extract

public abstract boolean extract
Indicates whether the first row of on the input should be extracted as a header row.

Returns:
a flag indicating whether to extract the headers from the first valid row when reading. If
Default:
false


Copyright © 2017 uniVocity Software Pty Ltd. All rights reserved.