public class JohnzonJsonb extends Object implements javax.json.bind.Jsonb, AutoCloseable, JsonbExtension
| Modifier and Type | Field and Description |
|---|---|
private org.apache.johnzon.mapper.Mapper |
delegate |
| Constructor and Description |
|---|
JohnzonJsonb(org.apache.johnzon.mapper.Mapper build) |
| Modifier and Type | Method and Description |
|---|---|
void |
close() |
<T> T |
fromJson(InputStream stream,
Class<T> type) |
<T> T |
fromJson(InputStream stream,
Type runtimeType) |
<T> T |
fromJson(Reader reader,
Class<T> type) |
<T> T |
fromJson(Reader reader,
Type runtimeType) |
<T> T |
fromJson(String str,
Class<T> type) |
<T> T |
fromJson(String str,
Type runtimeType) |
<T> T |
fromJsonValue(javax.json.JsonValue json,
Class<T> type) |
<T> T |
fromJsonValue(javax.json.JsonValue json,
Type type) |
private boolean |
isArray(Type runtimeType) |
private boolean |
isCollection(Type runtimeType) |
private Object[] |
toArray(Object object) |
String |
toJson(Object inObject) |
void |
toJson(Object inObject,
OutputStream stream) |
String |
toJson(Object inObject,
Type runtimeType) |
void |
toJson(Object inObject,
Type runtimeType,
OutputStream stream) |
void |
toJson(Object inObject,
Type runtimeType,
Writer writer) |
void |
toJson(Object inObject,
Writer writer) |
javax.json.JsonValue |
toJsonValue(Object object) |
javax.json.JsonValue |
toJsonValue(Object rawObject,
Type runtimeType) |
private Object |
unwrapOptional(Object inObject) |
private Type |
unwrapPrimitiveOptional(Type type) |
private <T> T |
wrapPrimitiveOptional(Object object,
Type type) |
public <T> T fromJson(String str, Class<T> type) throws javax.json.bind.JsonbException
fromJson in interface javax.json.bind.Jsonbjavax.json.bind.JsonbExceptionpublic <T> T fromJson(String str, Type runtimeType) throws javax.json.bind.JsonbException
fromJson in interface javax.json.bind.Jsonbjavax.json.bind.JsonbExceptionpublic <T> T fromJson(Reader reader, Class<T> type) throws javax.json.bind.JsonbException
fromJson in interface javax.json.bind.Jsonbjavax.json.bind.JsonbExceptionpublic <T> T fromJson(Reader reader, Type runtimeType) throws javax.json.bind.JsonbException
fromJson in interface javax.json.bind.Jsonbjavax.json.bind.JsonbExceptionpublic <T> T fromJson(InputStream stream, Class<T> type) throws javax.json.bind.JsonbException
fromJson in interface javax.json.bind.Jsonbjavax.json.bind.JsonbExceptionpublic <T> T fromJson(InputStream stream, Type runtimeType) throws javax.json.bind.JsonbException
fromJson in interface javax.json.bind.Jsonbjavax.json.bind.JsonbExceptionpublic String toJson(Object inObject) throws javax.json.bind.JsonbException
toJson in interface javax.json.bind.Jsonbjavax.json.bind.JsonbExceptionpublic String toJson(Object inObject, Type runtimeType) throws javax.json.bind.JsonbException
toJson in interface javax.json.bind.Jsonbjavax.json.bind.JsonbExceptionpublic void toJson(Object inObject, Writer writer) throws javax.json.bind.JsonbException
toJson in interface javax.json.bind.Jsonbjavax.json.bind.JsonbExceptionpublic void toJson(Object inObject, Type runtimeType, Writer writer) throws javax.json.bind.JsonbException
toJson in interface javax.json.bind.Jsonbjavax.json.bind.JsonbExceptionpublic void toJson(Object inObject, OutputStream stream) throws javax.json.bind.JsonbException
toJson in interface javax.json.bind.Jsonbjavax.json.bind.JsonbExceptionpublic void toJson(Object inObject, Type runtimeType, OutputStream stream) throws javax.json.bind.JsonbException
toJson in interface javax.json.bind.Jsonbjavax.json.bind.JsonbExceptionprivate boolean isArray(Type runtimeType)
private boolean isCollection(Type runtimeType)
public void close()
close in interface AutoCloseablepublic <T> T fromJsonValue(javax.json.JsonValue json,
Class<T> type)
fromJsonValue in interface JsonbExtensionpublic javax.json.JsonValue toJsonValue(Object object)
toJsonValue in interface JsonbExtensionpublic <T> T fromJsonValue(javax.json.JsonValue json,
Type type)
fromJsonValue in interface JsonbExtensionpublic javax.json.JsonValue toJsonValue(Object rawObject, Type runtimeType)
toJsonValue in interface JsonbExtensionCopyright © 2014–2019 The Apache Software Foundation. All rights reserved.