|Constructor and Description|
Create new writer model instance.
|Modifier and Type||Method and Description|
declaredTypes, isCustom, providedType, provider
public WriterModel(MessageBodyWriter provider, List<MediaType> types, Boolean custom)
provider- modelled message body writer instance.
types- supported media types as declared in
@Consumesannotation attached to the provider class.
custom- custom flag.
public boolean isWriteable(Class<?> type, Type genericType, Annotation annotations, MediaType mediaType)
isWriteablemethod on the underlying provider. Any exceptions will be logged at finer level.
type- the class of instance that is to be written.
genericType- the type of instance to be written, obtained either by reflection of a resource method return type or via inspection of the returned instance.
GenericEntityprovides a way to specify this information at runtime.
annotations- an array of the annotations attached to the message entity instance.
mediaType- the media type of the HTTP entity.
trueif the type is supported, otherwise
Copyright © 2007-2023, Oracle and/or its affiliates. All Rights Reserved. Use is subject to license terms.