- java.lang.Object
-
- com.github.mizosoft.methanol.adapter.ForwardingBodyAdapter
-
- All Implemented Interfaces:
BodyAdapter
- Direct Known Subclasses:
ForwardingDecoder,ForwardingEncoder
public abstract class ForwardingBodyAdapter extends java.lang.Object implements BodyAdapter
ABodyAdapterthat forwards calls to another.
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from interface com.github.mizosoft.methanol.BodyAdapter
BodyAdapter.Decoder, BodyAdapter.Encoder, BodyAdapter.Hints
-
-
Constructor Summary
Constructors Modifier Constructor Description protectedForwardingBodyAdapter()
-
Method Summary
All Methods Instance Methods Abstract Methods Concrete Methods Modifier and Type Method Description protected abstract BodyAdapterdelegate()Returns the adapter calls are being forwarded to.booleanisCompatibleWith(MediaType mediaType)Returnstrueif the format this adapter uses iscompatiblewith the given media type.booleansupportsType(TypeRef<?> type)Returnstrueif this adapter supports the given type.java.lang.StringtoString()
-
-
-
Method Detail
-
delegate
protected abstract BodyAdapter delegate()
Returns the adapter calls are being forwarded to.
-
isCompatibleWith
public boolean isCompatibleWith(MediaType mediaType)
Description copied from interface:BodyAdapterReturnstrueif the format this adapter uses iscompatiblewith the given media type.- Specified by:
isCompatibleWithin interfaceBodyAdapter
-
supportsType
public boolean supportsType(TypeRef<?> type)
Description copied from interface:BodyAdapterReturnstrueif this adapter supports the given type.- Specified by:
supportsTypein interfaceBodyAdapter
-
toString
public java.lang.String toString()
- Overrides:
toStringin classjava.lang.Object
-
-