public abstract class BaseHttpPartParser extends Object implements HttpPartParser
HttpPartParser
HttpPartParser.Null
Constructor and Description |
---|
BaseHttpPartParser() |
Modifier and Type | Method and Description |
---|---|
<T> ClassMeta<T> |
getClassMeta(Class<T> c)
Returns metadata about the specified class.
|
<T> ClassMeta<T> |
getClassMeta(Type t,
Type... args)
Returns metadata about the specified class.
|
<T> T |
parse(HttpPartType partType,
HttpPartSchema schema,
String in,
Class<T> toType)
Converts the specified input to the specified class type.
|
<T> T |
parse(HttpPartType partType,
HttpPartSchema schema,
String in,
ClassMeta<T> toType)
Converts the specified input to the specified class type.
|
<T> T |
parse(HttpPartType partType,
HttpPartSchema schema,
String in,
Type toType,
Type... toTypeArgs)
Converts the specified input to the specified class type.
|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
createPartSession
public BaseHttpPartParser()
public <T> T parse(HttpPartType partType, HttpPartSchema schema, String in, ClassMeta<T> toType) throws ParseException, SchemaValidationException
partType
- The part type being parsed.schema
- Schema information about the part.
in
- The input being parsed.toType
- The POJO type to transform the input into.ParseException
- Malformed input encountered.SchemaValidationException
- If the input or resulting HTTP part object fails schema validation.public <T> T parse(HttpPartType partType, HttpPartSchema schema, String in, Class<T> toType) throws ParseException, SchemaValidationException
partType
- The part type being parsed.schema
- Schema information about the part.
in
- The input being parsed.toType
- The POJO type to transform the input into.ParseException
- Malformed input encountered.SchemaValidationException
- If the input or resulting HTTP part object fails schema validation.public <T> T parse(HttpPartType partType, HttpPartSchema schema, String in, Type toType, Type... toTypeArgs) throws ParseException, SchemaValidationException
partType
- The part type being parsed.schema
- Schema information about the part.
in
- The input being parsed.toType
- The POJO type to transform the input into.toTypeArgs
- The generic type arguments of the POJO type to transform the input into.ParseException
- Malformed input encountered.SchemaValidationException
- If the input or resulting HTTP part object fails schema validation.public <T> ClassMeta<T> getClassMeta(Class<T> c)
HttpPartParser
getClassMeta
in interface HttpPartParser
T
- The class type.c
- The class type.public <T> ClassMeta<T> getClassMeta(Type t, Type... args)
HttpPartParser
getClassMeta
in interface HttpPartParser
T
- The class type.t
- The class type.args
- The class type args.Copyright © 2016–2020 The Apache Software Foundation. All rights reserved.