public class DataFormatReaders
extends java.lang.Object
DataFormatDetector
that needs to be used when
using data-binding.Modifier and Type | Class and Description |
---|---|
static class |
DataFormatReaders.Match
Result class, similar to
DataFormatMatcher |
Modifier and Type | Field and Description |
---|---|
static int |
DEFAULT_MAX_INPUT_LOOKAHEAD
By default we will look ahead at most 64 bytes; in most cases,
much less (4 bytes or so) is needed, but we will allow bit more
leniency to support data formats that need more complex heuristics.
|
Constructor and Description |
---|
DataFormatReaders(java.util.Collection<ObjectReader> detectors) |
DataFormatReaders(ObjectReader... detectors) |
Modifier and Type | Method and Description |
---|---|
DataFormatReaders.Match |
findFormat(byte[] fullInputData)
Method to call to find format that given content (full document)
has, as per configuration of this detector instance.
|
DataFormatReaders.Match |
findFormat(byte[] fullInputData,
int offset,
int len)
Method to call to find format that given content (full document)
has, as per configuration of this detector instance.
|
DataFormatReaders.Match |
findFormat(java.io.InputStream in)
Method to call to find format that content (accessible via given
InputStream ) given has, as per configuration of this detector
instance. |
java.lang.String |
toString() |
DataFormatReaders |
with(DeserializationConfig config) |
DataFormatReaders |
with(ObjectReader[] readers) |
DataFormatReaders |
withMaxInputLookahead(int lookaheadBytes) |
DataFormatReaders |
withMinimalMatch(MatchStrength minMatch) |
DataFormatReaders |
withOptimalMatch(MatchStrength optMatch) |
DataFormatReaders |
withType(JavaType type) |
public static final int DEFAULT_MAX_INPUT_LOOKAHEAD
public DataFormatReaders(ObjectReader... detectors)
public DataFormatReaders(java.util.Collection<ObjectReader> detectors)
public DataFormatReaders withOptimalMatch(MatchStrength optMatch)
public DataFormatReaders withMinimalMatch(MatchStrength minMatch)
public DataFormatReaders with(ObjectReader[] readers)
public DataFormatReaders withMaxInputLookahead(int lookaheadBytes)
public DataFormatReaders with(DeserializationConfig config)
public DataFormatReaders withType(JavaType type)
public DataFormatReaders.Match findFormat(java.io.InputStream in) throws java.io.IOException
InputStream
) given has, as per configuration of this detector
instance.java.io.IOException
public DataFormatReaders.Match findFormat(byte[] fullInputData) throws java.io.IOException
java.io.IOException
public DataFormatReaders.Match findFormat(byte[] fullInputData, int offset, int len) throws java.io.IOException
java.io.IOException
public java.lang.String toString()
toString
in class java.lang.Object
Copyright © 2010 - 2020 Adobe. All Rights Reserved