Class NumberSerializer
- java.lang.Object
-
- io.quarkus.reactivemessaging.http.runtime.serializers.NumberSerializer
-
- All Implemented Interfaces:
Serializer<Number>
public class NumberSerializer extends Object implements Serializer<Number>
Serializer for numbers
-
-
Field Summary
-
Fields inherited from interface io.quarkus.reactivemessaging.http.runtime.serializers.Serializer
DEFAULT_PRIORITY
-
-
Constructor Summary
Constructors Constructor Description NumberSerializer()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description boolean
handles(Object payload)
if the serializer can handle given payloadio.vertx.core.buffer.Buffer
serialize(Number payload)
serialize the payload-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface io.quarkus.reactivemessaging.http.runtime.serializers.Serializer
getPriority
-
-
-
-
Method Detail
-
handles
public boolean handles(Object payload)
Description copied from interface:Serializer
if the serializer can handle given payload- Specified by:
handles
in interfaceSerializer<Number>
- Parameters:
payload
- the payload- Returns:
- true iff the seralizer can handle the payload
-
serialize
public io.vertx.core.buffer.Buffer serialize(Number payload)
Description copied from interface:Serializer
serialize the payload- Specified by:
serialize
in interfaceSerializer<Number>
- Parameters:
payload
- object to serialize- Returns:
- a buffer with serialized payload
-
-