Class JsonMarshallerContext
- java.lang.Object
-
- software.amazon.awssdk.protocols.json.internal.marshall.JsonMarshallerContext
-
public final class JsonMarshallerContext extends Object
Dependencies needed by implementations ofJsonMarshaller.
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static classJsonMarshallerContext.BuilderBuilder for aJsonMarshallerContext.
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description static JsonMarshallerContext.Builderbuilder()StructuredJsonGeneratorjsonGenerator()voidmarshall(MarshallLocation marshallLocation, Object val)Convenience method to marshall a nested object (may be simple or structured) at the given location.<T> voidmarshall(MarshallLocation marshallLocation, T val, String paramName)Convenience method to marshall a nested object (may be simple or structured) at the given location.JsonMarshallerRegistrymarshallerRegistry()JsonProtocolMarshallerprotocolHandler()SdkHttpFullRequest.Builderrequest()
-
-
-
Method Detail
-
jsonGenerator
public StructuredJsonGenerator jsonGenerator()
- Returns:
- StructuredJsonGenerator used to produce the JSON document for a request.
-
protocolHandler
public JsonProtocolMarshaller protocolHandler()
- Returns:
- Implementation of
ProtocolMarshallerthat can be used to call back out to marshall structured data (i.e. dlists of objects).
-
marshallerRegistry
public JsonMarshallerRegistry marshallerRegistry()
- Returns:
- Marshaller registry to obtain marshaller implementations for nested types (i.e. lists of objects or maps of string to string).
-
request
public SdkHttpFullRequest.Builder request()
- Returns:
- Mutable
SdkHttpFullRequest.Builderobject that can be used to add headers, query params, modify request URI, etc.
-
marshall
public void marshall(MarshallLocation marshallLocation, Object val)
Convenience method to marshall a nested object (may be simple or structured) at the given location.- Parameters:
marshallLocation- CurrentMarshallLocationval- Value to marshall.
-
marshall
public <T> void marshall(MarshallLocation marshallLocation, T val, String paramName)
Convenience method to marshall a nested object (may be simple or structured) at the given location.- Parameters:
marshallLocation- CurrentMarshallLocationval- Value to marshall.paramName- Name of parameter to marshall.
-
builder
public static JsonMarshallerContext.Builder builder()
- Returns:
- Builder instance to construct a
JsonMarshallerContext.
-
-