BeanIO 2.0.4

org.beanio.internal.config
Class SimplePropertyConfig

java.lang.Object
  extended by org.beanio.internal.util.TreeNode<ComponentConfig>
      extended by org.beanio.internal.config.ComponentConfig
          extended by org.beanio.internal.config.PropertyConfig
              extended by org.beanio.internal.config.SimplePropertyConfig
All Implemented Interfaces:
Cloneable, Iterable<ComponentConfig>, Replicateable
Direct Known Subclasses:
ConstantConfig, FieldConfig

public abstract class SimplePropertyConfig
extends PropertyConfig

A base class for configuration components that can be bound to "simple attributes" of a bean object. A simple attribute is one that does not have any child properties itself and can be derived using a TypeHandler.

Since:
2.0
Author:
Kevin Seim

Field Summary
 
Fields inherited from class org.beanio.internal.config.PropertyConfig
JSON_TYPE_ARRAY, JSON_TYPE_BOOLEAN, JSON_TYPE_NONE, JSON_TYPE_NUMBER, JSON_TYPE_OBJECT, JSON_TYPE_STRING
 
Fields inherited from class org.beanio.internal.config.ComponentConfig
CONSTANT, FIELD, GROUP, RECORD, SEGMENT, STREAM, WRAPPER
 
Constructor Summary
SimplePropertyConfig()
          Constructs a new SimplePropertyConfig.
 
Method Summary
 String getFormat()
          Returns the pattern used by date and number type handlers to parse and format the property value.
 String getTypeHandler()
          Returns the name of the custom type handler used for type conversion by this component, or null if the default type handler is sufficient.
 void setFormat(String format)
          Sets the pattern used by date and number type handlers to parse and format the property value.
 void setTypeHandler(String handler)
          Sets the name of the custom type handler to use for type conversion by this component.
 
Methods inherited from class org.beanio.internal.config.PropertyConfig
getCollection, getGetter, getJsonArrayIndex, getJsonName, getJsonType, getKey, getMaxOccurs, getMaxSize, getMinOccurs, getMinSize, getPosition, getSetter, getType, getUntil, getXmlType, isBound, isCollection, isIdentifier, isJsonArray, isLazy, isNillable, isRepeating, isSupportedChild, setBound, setCollection, setGetter, setIdentifier, setJsonArray, setJsonArrayIndex, setJsonName, setJsonType, setMaxOccurs, setMaxSize, setMinOccurs, setMinSize, setNillable, setPosition, setSetter, setType, setUntil, setXmlType
 
Methods inherited from class org.beanio.internal.config.ComponentConfig
getComponentType, getXmlName, getXmlNamespace, getXmlPrefix, isXmlNamespaceAware, setXmlName, setXmlNamespace, setXmlNamespaceAware, setXmlPrefix
 
Methods inherited from class org.beanio.internal.util.TreeNode
add, clone, find, getChildren, getFirst, getName, iterator, print, setName, size, sort, toParamString, toString, updateReferences
 
Methods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

SimplePropertyConfig

public SimplePropertyConfig()
Constructs a new SimplePropertyConfig.

Method Detail

getTypeHandler

public String getTypeHandler()
Returns the name of the custom type handler used for type conversion by this component, or null if the default type handler is sufficient.

Returns:
the name of a custom type handler

setTypeHandler

public void setTypeHandler(String handler)
Sets the name of the custom type handler to use for type conversion by this component. Set to null if the default type handler is sufficient.

Parameters:
handler - the name of a custom type handler

getFormat

public String getFormat()
Returns the pattern used by date and number type handlers to parse and format the property value.

Returns:
the date or number format pattern
See Also:
SimpleDateFormat, DecimalFormat

setFormat

public void setFormat(String format)
Sets the pattern used by date and number type handlers to parse and format the property value.

Parameters:
format - the date or number format pattern
See Also:
SimpleDateFormat, DecimalFormat

BeanIO 2.0.4

Copyright © 2010-2013 Kevin Seim