org.red5.server.net.rtmp.codec

## Interface IEventEncoder

All Known Implementing Classes:
  RTMPProtocolEncoder, RTMPTProtocolEncoder

    public interface IEventEncoder

Encodes events to byte buffer.

### Method Summary

Methods
`IoBuffer` `encodeAggregate(Aggregate aggregate)` Encodes Aggregate event to byte buffer.
`IoBuffer` `encodeAudioData(AudioData audioData)` Encodes AudioData event to byte buffer.
`IoBuffer` `encodeBytesRead(BytesRead streamBytesRead)` Encodes BytesRead event to byte buffer.
`IoBuffer` `encodeChunkSize(ChunkSize chunkSize)` Encodes ChunkSize event to byte buffer.
`IoBuffer` `encodeFlexSharedObject(ISharedObjectMessage so, RTMP rtmp)` Encodes SharedObjectMessage event to byte buffer using AMF3 encoding.
`IoBuffer` `encodeInvoke(Invoke invoke, RTMP rtmp)` Encodes Invoke event to byte buffer.
`IoBuffer` `encodeNotify(Notify notify, RTMP rtmp)` Encodes Notify event to byte buffer.
`IoBuffer` `encodePing(Ping ping)` Encodes Ping event to byte buffer.
`IoBuffer` `encodeSharedObject(ISharedObjectMessage so, RTMP rtmp)` Encodes SharedObjectMessage event to byte buffer.
`IoBuffer` `encodeUnknown(Unknown unknown)` Encodes Unknown event to byte buffer.
`IoBuffer` `encodeVideoData(VideoData videoData)` Encodes VideoData event to byte buffer.

### Method Detail

#### encodeNotify

    IoBuffer encodeNotify(Notify notify,
                        RTMP rtmp)

Encodes Notify event to byte buffer.

Parameters:
  `notify` - Notify event
  `rtmp` - RTMP protocol state
Returns:
  Byte buffer

#### encodeInvoke

    IoBuffer encodeInvoke(Invoke invoke,
                        RTMP rtmp)

Encodes Invoke event to byte buffer.

Parameters:
  `invoke` - Invoke event
  `rtmp` - RTMP protocol state
Returns:
  Byte buffer

#### encodePing

    IoBuffer encodePing(Ping ping)

Encodes Ping event to byte buffer.

Parameters:
  `ping` - Ping event
Returns:
  Byte buffer

#### encodeBytesRead

    IoBuffer encodeBytesRead(BytesRead streamBytesRead)

Encodes BytesRead event to byte buffer.

Parameters:
  `streamBytesRead` - BytesRead event
Returns:
  Byte buffer

#### encodeAggregate

    IoBuffer encodeAggregate(Aggregate aggregate)

Encodes Aggregate event to byte buffer.

Parameters:
  `aggregate` - Aggregate event
Returns:
  Byte buffer

#### encodeAudioData

    IoBuffer encodeAudioData(AudioData audioData)

Encodes AudioData event to byte buffer.

Parameters:
  `audioData` - AudioData event
Returns:
  Byte buffer

#### encodeVideoData

    IoBuffer encodeVideoData(VideoData videoData)

Encodes VideoData event to byte buffer.

Parameters:
  `videoData` - VideoData event
Returns:
  Byte buffer

#### encodeUnknown

    IoBuffer encodeUnknown(Unknown unknown)

Encodes Unknown event to byte buffer.

Parameters:
  `unknown` - Unknown event
Returns:
  Byte buffer

#### encodeChunkSize

    IoBuffer encodeChunkSize(ChunkSize chunkSize)

Encodes ChunkSize event to byte buffer.

Parameters:
  `chunkSize` - ChunkSize event
Returns:
  Byte buffer

#### encodeSharedObject

    IoBuffer encodeSharedObject(ISharedObjectMessage so,
                              RTMP rtmp)

Encodes SharedObjectMessage event to byte buffer.

Parameters:
  `so` - ISharedObjectMessage event
  `rtmp` - RTMP protocol state
Returns:
  Byte buffer

#### encodeFlexSharedObject

    IoBuffer encodeFlexSharedObject(ISharedObjectMessage so,
                                  RTMP rtmp)

Encodes SharedObjectMessage event to byte buffer using AMF3 encoding.

Parameters:
  `so` - ISharedObjectMessage event
  `rtmp` - RTMP protocol state
Returns:
  Byte buffer