com.kuka.comm.codec.bytebuffer
Class ByteOrderEncoder
java.lang.Object
com.kuka.comm.codec.Encoder<Object,ByteBuffer>
com.kuka.comm.codec.bytebuffer.ByteOrderEncoder
public final class ByteOrderEncoder
- extends Encoder<Object,ByteBuffer>
An Encoder to modify the byte order of a ByteBuffer. The position and limit of the passed byte buffer
will not be changed.
|
Constructor Summary |
ByteOrderEncoder(ByteOrder byteOrder)
Creates a new encoder, that modifies the byte order of the given byte buffer. |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
ByteOrderEncoder
public ByteOrderEncoder(ByteOrder byteOrder)
- Creates a new encoder, that modifies the byte order of the given byte buffer.
- Parameters:
byteOrder - the preferred byte order, either ByteOrder.BIG_ENDIAN or ByteOrder.LITTLE_ENDIAN
encodeImpl
protected void encodeImpl(Object in,
ByteBuffer out)
- Description copied from class:
Encoder
- Override this method to implement encoding process.
Note: You should override either this method or Encoder.encodeImpl(Object, Object, EncoderContext).
Overriding both will have no effect, i.e. only Encoder.encodeImpl(Object, Object, EncoderContext) will be
called.
- Overrides:
encodeImpl in class Encoder<Object,ByteBuffer>
- Parameters:
in - the input for this encoderout - the output for this encoder- See Also:
Encoder.encodeImpl(Object, Object, EncoderContext)
Copyright © 2019. All rights reserved.