|
||||||||||
| 前のクラス 次のクラス | フレームあり フレームなし | |||||||||
| 概要: 入れ子 | フィールド | コンストラクタ | メソッド | 詳細: フィールド | コンストラクタ | メソッド | |||||||||
java.lang.Objectjp.terasoluna.fw.file.dao.standard.AbstractFileLineIterator<T>
jp.terasoluna.fw.file.dao.standard.FixedFileLineIterator<T>
T - ファイル行オブジェクト。public class FixedFileLineIterator<T>
固定長ファイル用のファイルアクセス(データ取得)クラス。
固定長ファイルからデータを読み込み、 1行分のデータをファイル行オブジェクトに格納する。
※利用するファイル行オブジェクトのアノテーション項目FileFormatの設定項目| 論理項目名 | 物理項目名 | デフォルト値 | 必須性 |
行区切り文字 |
lineFeedChar |
システムの行区切り文字 |
オプション |
ファイルエンコーディング |
fileEncodeing |
システムのファイルエンコーディング |
オプション |
ヘッダ行数 |
headerLineCount |
0 |
オプション |
トレイら行数 |
trailerLineCount |
0 |
オプション |
InputFileColumn、@OutputFileColumnの設定項目| 論理項目名 | 物理項目名 | デフォルト値 | 必須性 |
カラムインデックス |
columnIndex |
- | 必須 |
フォーマット |
columnFormat |
"" |
オプション |
バイト長 |
bytes |
-1 |
オプション |
パディング種別 |
paddingType |
パディングなし |
オプション |
パディング文字 |
paddingChar |
' ' |
オプション |
トリム種別 |
trimType |
トリムなし |
オプション |
トリム文字 |
trimChar |
' ' |
オプション |
文字変換種別 |
stringConverter |
NullStringConverter.class |
オプション |
| フィールドの概要 | |
|---|---|
private static char |
DELIMITER
区切り文字。 |
private static char |
ENCLOSE_CHAR
囲み文字。 |
| コンストラクタの概要 | |
|---|---|
FixedFileLineIterator(java.lang.String fileName,
java.lang.Class<T> clazz,
java.util.Map<java.lang.String,ColumnParser> textSetterMap)
コンストラクタ。 |
|
| メソッドの概要 | |
|---|---|
char |
getDelimiter()
区切り文字を取得する。 |
char |
getEncloseChar()
囲み文字を取得する。 |
protected java.lang.String[] |
separateColumns(java.lang.String fileLineString)
読み込んだ固定長のレコードをアノテーションのbyte数、 columnIndex従って分解する。 |
| クラス jp.terasoluna.fw.file.dao.standard.AbstractFileLineIterator から継承されたメソッド |
|---|
closeFile, getCurrentLineCount, getFields, getFileEncoding, getFileName, getHeader, getHeaderLineCount, getLineFeedChar, getTrailer, getTrailerLineCount, hasNext, init, next, readLine, remove, skip |
| クラス java.lang.Object から継承されたメソッド |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| フィールドの詳細 |
|---|
private static final char DELIMITER
private static final char ENCLOSE_CHAR
| コンストラクタの詳細 |
|---|
public FixedFileLineIterator(java.lang.String fileName,
java.lang.Class<T> clazz,
java.util.Map<java.lang.String,ColumnParser> textSetterMap)
fileName - ファイル名clazz - 結果クラスtextSetterMap - フォーマット処理リスト| メソッドの詳細 |
|---|
protected java.lang.String[] separateColumns(java.lang.String fileLineString)
処理の順序は、
AbstractFileLineIterator<T> 内の separateColumnsfileLineString - 固定長ファイルのの1レコード分の文字列
public char getDelimiter()
AbstractFileLineIterator<T> 内の getDelimiterpublic char getEncloseChar()
AbstractFileLineIterator<T> 内の getEncloseChar
|
||||||||||
| 前のクラス 次のクラス | フレームあり フレームなし | |||||||||
| 概要: 入れ子 | フィールド | コンストラクタ | メソッド | 詳細: フィールド | コンストラクタ | メソッド | |||||||||