ThinkUI SQL Client 1.1.3 API

thinkui.parser
Class FixedWidthDataObjectParser

java.lang.Object
  extended bythinkui.parser.FixedWidthDataObjectParser
All Implemented Interfaces:
ColumnParser, DataObjectParser

public class FixedWidthDataObjectParser
extends java.lang.Object
implements DataObjectParser

Implement a fixed-width text parser for a data object by using a data-driven approach. Parse information is stored in an array of ColumnParseData objects for each column (e.g. attribute). The Attribute type is used to perform the parsing of the string value. For non-default parsing, a custom ColumnParser can be configured on a per-column basis or a CompoundColumnParser can be used if the column actually maps to multiple data object attributes.


Constructor Summary
FixedWidthDataObjectParser(ColumnParseData[] parseData)
          FixedWidthDataObjectParser constructor.
 
Method Summary
 void parse(DataObject dataObject, java.lang.String line)
          Parse the given row data and populate the appropriate attributes in the given data object.
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

FixedWidthDataObjectParser

public FixedWidthDataObjectParser(ColumnParseData[] parseData)
FixedWidthDataObjectParser constructor.

Method Detail

parse

public void parse(DataObject dataObject,
                  java.lang.String line)
           throws java.lang.Exception
Parse the given row data and populate the appropriate attributes in the given data object.

Specified by:
parse in interface ColumnParser
Throws:
java.lang.Exception

ThinkUI SQL Client 1.1.3 API

Copyright © 2007-2009. ThinkUI Software Inc. All rights reserved.