ServerCodec

object ServerCodec extends PacketCodec
trait PacketCodec
class Object
trait Matchable
class Any

Value members

Concrete methods

override def decodeMessage(name: String, b: ByteBuffer): Message
Definition Classes
PacketCodec
def encodeBundle(bndl: Bundle, b: ByteBuffer): Unit
def encodeMessage(msg: Message, b: ByteBuffer): Unit
def encodedMessageSize(msg: Message): Int
def printAtom(value: Any, stream: PrintStream, nestCount: Int): Unit

Inherited methods

@throws(scala.Predef.classOf[scala.Exception])
final def decode(b: ByteBuffer): Packet

Creates a new packet decoded from the ByteBuffer. This method tries to read a null terminated string at the beginning of the provided buffer. If it equals the bundle identifier, the decode of Bundle is called (which may recursively decode nested bundles), otherwise the one from Message.

Creates a new packet decoded from the ByteBuffer. This method tries to read a null terminated string at the beginning of the provided buffer. If it equals the bundle identifier, the decode of Bundle is called (which may recursively decode nested bundles), otherwise the one from Message.

This method is final. For messages encountered, decodeMessage is called, , thus for implementations of PacketCodec, it is sufficient to overwrite decodeMessage.

Value Params
b

ByteBuffer pointing right at the beginning of the packet. the buffer's limited should be set appropriately to allow the complete packet to be read. when the method returns, the buffer's position is right after the end of the packet.

Returns

new decoded OSC packet

Inherited from
PacketCodec
@throws(scala.Predef.classOf[scala.Exception])
final def decodeBundle(b: ByteBuffer): Bundle
Inherited from
PacketCodec
final def encodedBundleSize(bndl: Bundle): Int

Calculates the byte size of the encoded bundle. This method is final. The size is the sum of the bundle name, its time-tag and the sizes of each bundle element.

Calculates the byte size of the encoded bundle. This method is final. The size is the sum of the bundle name, its time-tag and the sizes of each bundle element.

For contained messages, encodedMessageSize will be called, thus for implementations of PacketCodec, it is sufficient to overwrite encodedMessageSize.

Inherited from
PacketCodec

Concrete fields

final val charsetName: String