public enum NoMarshaller extends Enum<NoMarshaller> implements BytesMarshaller<Void>
Enum Constant and Description |
---|
INSTANCE |
Modifier and Type | Method and Description |
---|---|
Void |
read(Bytes bytes)
Reads and returns an object from
bytes . |
Void |
read(Bytes bytes,
Void aVoid)
Reads and returns an object from
bytes , reusing the given object, if possible. |
static NoMarshaller |
valueOf(String name)
Returns the enum constant of this type with the specified name.
|
static NoMarshaller[] |
values()
Returns an array containing the constants of this enum type, in
the order they are declared.
|
void |
write(Bytes bytes,
Void aVoid)
Write the object out to the
bytes . |
public static final NoMarshaller INSTANCE
public static NoMarshaller[] values()
for (NoMarshaller c : NoMarshaller.values()) System.out.println(c);
public static NoMarshaller valueOf(String name)
name
- the name of the enum constant to be returned.IllegalArgumentException
- if this enum type has no constant with the specified nameNullPointerException
- if the argument is nullpublic void write(Bytes bytes, Void aVoid)
BytesMarshaller
bytes
.write
in interface BytesMarshaller<Void>
bytes
- to write toaVoid
- the object to writepublic Void read(Bytes bytes)
BytesMarshaller
bytes
.read
in interface BytesMarshaller<Void>
bytes
- to read@Nullable public Void read(Bytes bytes, @Nullable Void aVoid)
BytesMarshaller
bytes
, reusing the given object, if possible.read
in interface BytesMarshaller<Void>
bytes
- to readaVoid
- an object to reuse, if possible. null
could be passed, in this case
a new object should be allocated anyway.Copyright © 2019. All rights reserved.