- java.lang.Object
-
- io.xlate.edi.stream.PropertySupport
-
- io.xlate.edi.stream.EDIInputFactory
-
- io.xlate.edi.internal.stream.StaEDIInputFactory
-
public class StaEDIInputFactory extends EDIInputFactory
-
-
Field Summary
-
Fields inherited from class io.xlate.edi.stream.EDIInputFactory
EDI_VALIDATE_CONTROL_STRUCTURE
-
Fields inherited from class io.xlate.edi.stream.PropertySupport
properties, supportedProperties
-
-
Constructor Summary
Constructors Constructor Description StaEDIInputFactory()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description EDIStreamReadercreateEDIStreamReader(InputStream stream)Creates a newEDIStreamReaderusing the givenInputStream(with default encoding).EDIStreamReadercreateEDIStreamReader(InputStream stream, Schema schema)Creates a newEDIStreamReaderusing the givenInputStream(with default encoding) which uses theSchemafor validation of the input's control structures (interchange, group, transaction).EDIStreamReadercreateEDIStreamReader(InputStream stream, String encoding)Creates a newEDIStreamReaderusing the givenInputStreamand encoding.EDIStreamReadercreateEDIStreamReader(InputStream stream, String encoding, Schema schema)Creates a newEDIStreamReaderusing the givenInputStreamand encoding which uses theSchemafor validation of the input's control structures (interchange, group, transaction).EDIStreamReadercreateFilteredReader(EDIStreamReader reader, EDIStreamFilter filter)Creates a newEDIStreamReaderby wrapping the given reader with theEDIStreamFilterfilter.-
Methods inherited from class io.xlate.edi.stream.EDIInputFactory
newFactory
-
Methods inherited from class io.xlate.edi.stream.PropertySupport
getProperty, isPropertySupported, setProperty
-
-
-
-
Method Detail
-
createEDIStreamReader
public EDIStreamReader createEDIStreamReader(InputStream stream)
Description copied from class:EDIInputFactoryCreates a newEDIStreamReaderusing the givenInputStream(with default encoding).- Specified by:
createEDIStreamReaderin classEDIInputFactory- Parameters:
stream-InputStreamfrom which the EDI data will be read- Returns:
- a new
EDIStreamReaderwhich reads from the stream
-
createEDIStreamReader
public EDIStreamReader createEDIStreamReader(InputStream stream, String encoding) throws EDIStreamException
Description copied from class:EDIInputFactoryCreates a newEDIStreamReaderusing the givenInputStreamand encoding.- Specified by:
createEDIStreamReaderin classEDIInputFactory- Parameters:
stream-InputStreamfrom which the EDI data will be readencoding- character encoding of the stream- Returns:
- a new
EDIStreamReaderwhich reads from the stream - Throws:
EDIStreamException- when encoding is not supported
-
createEDIStreamReader
public EDIStreamReader createEDIStreamReader(InputStream stream, Schema schema)
Description copied from class:EDIInputFactoryCreates a newEDIStreamReaderusing the givenInputStream(with default encoding) which uses theSchemafor validation of the input's control structures (interchange, group, transaction). Note that a separate schema for validation of messages/transactions may be passed directly to theEDIStreamReaderonce the type and version of the messages is known.- Specified by:
createEDIStreamReaderin classEDIInputFactory- Parameters:
stream-InputStreamfrom which the EDI data will be readschema-Schemafor control structure validation- Returns:
- a new
EDIStreamReaderwhich reads from the stream
-
createEDIStreamReader
public EDIStreamReader createEDIStreamReader(InputStream stream, String encoding, Schema schema) throws EDIStreamException
Description copied from class:EDIInputFactoryCreates a newEDIStreamReaderusing the givenInputStreamand encoding which uses theSchemafor validation of the input's control structures (interchange, group, transaction). Note that a separate schema for validation of messages/transactions may be passed directly to theEDIStreamReaderonce the type and version of the messages is known.- Specified by:
createEDIStreamReaderin classEDIInputFactory- Parameters:
stream-InputStreamfrom which the EDI data will be readencoding- character encoding of the streamschema-Schemafor control structure validation- Returns:
- a new
EDIStreamReaderwhich reads from the stream - Throws:
EDIStreamException- when encoding is not supported
-
createFilteredReader
public EDIStreamReader createFilteredReader(EDIStreamReader reader, EDIStreamFilter filter)
Description copied from class:EDIInputFactoryCreates a newEDIStreamReaderby wrapping the given reader with theEDIStreamFilterfilter.- Specified by:
createFilteredReaderin classEDIInputFactory- Parameters:
reader- the reader to wrapfilter- a filter to wrap the given reader- Returns:
- a new
EDIStreamReaderwhich uses filter
-
-