public class AvroItemWriter<T> extends AbstractItemStreamItemWriter<T>
WritableResource
に直列化する ItemWriter
。これは、障害時の再起動をサポートしていません。コンストラクターと説明 |
---|
AvroItemWriter(org.springframework.core.io.WritableResource resource, java.lang.Class<T> clazz) このコンストラクターは、Avro スキーマを埋め込まない ItemWriter を作成します。 |
AvroItemWriter(org.springframework.core.io.WritableResource resource, org.springframework.core.io.Resource schema, java.lang.Class<T> clazz) |
修飾子と型 | メソッドと説明 |
---|---|
void | close() ノーオペレーション。 |
void | open(ExecutionContext executionContext) ノーオペレーション。 |
void | write(java.util.List<? extends T> items) 指定されたデータ要素を処理します。 |
getExecutionContextKey, setExecutionContextName, setName, update
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
update
public AvroItemWriter(org.springframework.core.io.WritableResource resource, org.springframework.core.io.Resource schema, java.lang.Class<T> clazz)
resource
- オブジェクトが直列化される WritableResource
。schema
- Avro スキーマを含む Resource
。clazz
- 直列化するデータ型。public AvroItemWriter(org.springframework.core.io.WritableResource resource, java.lang.Class<T> clazz)
resource
- オブジェクトが直列化される WritableResource
。clazz
- 直列化するデータ型。public void write(java.util.List<? extends T> items) throws java.lang.Exception
ItemWriter
items
- 書かれる項目 java.lang.Exception
- エラーがある場合。フレームワークは例外をキャッチし、必要に応じて変換または再スローします。public void open(ExecutionContext executionContext)
ItemStreamSupport
ItemStream
の open
ItemStreamSupport
の open
executionContext
- 現在のステップの ExecutionContext
再起動時のステップの最後の実行からの executionContext になります。ItemStream.open(ExecutionContext)
public void close()
ItemStreamSupport
ItemStream
の close
ItemStreamSupport
の close
ItemStream.close()