|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.red5.server.AttributeStore
org.red5.server.BaseConnection
org.red5.server.net.rtmp.RTMPConnection
org.red5.server.net.rtmp.RTMPMinaConnection
@ManagedResource public class RTMPMinaConnection
Represents an RTMP connection using Mina.
Nested Class Summary |
---|
Nested classes/interfaces inherited from interface org.red5.server.api.IConnection |
---|
IConnection.Encoding |
Field Summary | |
---|---|
protected boolean |
bandwidthDetection
|
protected int |
defaultClientBandwidth
|
protected int |
defaultServerBandwidth
|
protected static Logger |
log
|
Fields inherited from class org.red5.server.net.rtmp.RTMPConnection |
---|
bytesReadInterval, clientId, limitType, nextBytesRead, RTMP_CONNECTION_KEY, RTMP_ENCRYPTED, RTMP_HANDSHAKE, RTMP_NON_ENCRYPTED, RTMPE_CIPHER_IN, RTMPE_CIPHER_OUT, schedulingService, state |
Fields inherited from class org.red5.server.BaseConnection |
---|
basicScopes, client, closed, connectionListeners, droppedMessages, host, params, path, readMessages, remoteAddress, remoteAddresses, remotePort, scope, sessionId, type, writtenMessages |
Fields inherited from class org.red5.server.AttributeStore |
---|
attributes |
Fields inherited from interface org.red5.server.api.IConnection |
---|
PERSISTENT, POLLING, TRANSIENT |
Constructor Summary | |
---|---|
RTMPMinaConnection()
Constructs a new RTMPMinaConnection. |
Method Summary | |
---|---|
void |
close()
Closes connection |
boolean |
connect(IScope newScope,
Object[] params)
Connect to another scope on server with given parameters |
int |
getDefaultClientBandwidth()
|
int |
getDefaultServerBandwidth()
|
IoSession |
getIoSession()
Return MINA I/O session. |
int |
getLimitType()
|
long |
getPendingMessages()
Count of outgoing messages not yet written. |
long |
getReadBytes()
Total number of bytes read from the connection. |
long |
getWrittenBytes()
Total number of bytes written to the connection. |
void |
invokeMethod(String method)
|
boolean |
isBandwidthDetection()
|
boolean |
isConnected()
Check whether connection is alive |
boolean |
isReaderIdle()
Returns whether or not the reader is idle. |
boolean |
isWriterIdle()
Returns whether or not the writer is idle. |
protected void |
onInactive()
Inactive state event handler. |
protected void |
registerJMX()
|
void |
setBandwidthDetection(boolean bandwidthDetection)
|
void |
setDefaultClientBandwidth(int defaultClientBandwidth)
|
void |
setDefaultServerBandwidth(int defaultServerBandwidth)
|
void |
setIoSession(IoSession protocolSession)
Setter for MINA I/O session (connection). |
void |
setLimitType(int limitType)
|
protected void |
unregisterJMX()
|
void |
write(Packet out)
Write packet. |
void |
writeRaw(IoBuffer out)
Write raw byte buffer. |
Methods inherited from class org.red5.server.BaseConnection |
---|
addListener, connect, dispatchEvent, getBasicScopes, getClient, getConnectParams, getDroppedMessages, getHost, getLock, getNextClientId, getPath, getReadMessages, getRemoteAddress, getRemoteAddresses, getRemotePort, getScope, getSessionId, getType, getWrittenMessages, handleEvent, initialize, notifyEvent, registerBasicScope, removeListener, unregisterBasicScope |
Methods inherited from class org.red5.server.AttributeStore |
---|
filterNull, from, getAttribute, getAttribute, getAttributeNames, getAttributes, getBoolAttribute, getByteAttribute, getDoubleAttribute, getIntAttribute, getListAttribute, getLongAttribute, getMapAttribute, getSetAttribute, getShortAttribute, getStringAttribute, hasAttribute, removeAttribute, removeAttributes, setAttribute, setAttributes, setAttributes, size |
Methods inherited from class java.lang.Object |
---|
clone, finalize, getClass, notify, notifyAll, wait, wait, wait |
Methods inherited from interface org.red5.server.jmx.mxbeans.RTMPMinaConnectionMXBean |
---|
getDroppedMessages, getHost, getPath, getPendingVideoMessages, getReadMessages, getRemoteAddress, getRemoteAddresses, getRemotePort, getSessionId, getType, getWrittenMessages |
Methods inherited from interface org.red5.server.jmx.mxbeans.AttributeStoreMXBean |
---|
getAttributeNames, hasAttribute, removeAttribute, removeAttributes |
Methods inherited from interface org.red5.server.api.IConnection |
---|
addListener, connect, getBasicScopes, getClient, getConnectParams, getDroppedMessages, getHost, getPath, getReadMessages, getRemoteAddress, getRemoteAddresses, getRemotePort, getScope, getSessionId, getType, getWrittenMessages, initialize, removeListener |
Methods inherited from interface org.red5.server.api.event.IEventDispatcher |
---|
dispatchEvent |
Methods inherited from interface org.red5.server.api.event.IEventHandler |
---|
handleEvent |
Methods inherited from interface org.red5.server.api.event.IEventListener |
---|
notifyEvent |
Methods inherited from interface org.red5.server.api.ICastingAttributeStore |
---|
getBoolAttribute, getByteAttribute, getDoubleAttribute, getIntAttribute, getListAttribute, getLongAttribute, getMapAttribute, getSetAttribute, getShortAttribute, getStringAttribute |
Methods inherited from interface org.red5.server.api.IAttributeStore |
---|
getAttribute, getAttribute, getAttributeNames, getAttributes, hasAttribute, removeAttribute, removeAttributes, setAttribute, setAttributes, setAttributes, size |
Field Detail |
---|
protected static Logger log
protected int defaultServerBandwidth
protected int defaultClientBandwidth
protected boolean bandwidthDetection
Constructor Detail |
---|
@ConstructorProperties(value="persistent") public RTMPMinaConnection()
Method Detail |
---|
public boolean connect(IScope newScope, Object[] params)
BaseConnection
connect
in interface IConnection
connect
in class RTMPConnection
newScope
- New scopeparams
- Parameters to connect with
public void close()
close
in interface IConnection
close
in interface RTMPMinaConnectionMXBean
close
in class RTMPConnection
public IoSession getIoSession()
public int getDefaultServerBandwidth()
public void setDefaultServerBandwidth(int defaultServerBandwidth)
defaultServerBandwidth
- the defaultServerBandwidth to setpublic int getDefaultClientBandwidth()
public void setDefaultClientBandwidth(int defaultClientBandwidth)
defaultClientBandwidth
- the defaultClientBandwidth to setpublic int getLimitType()
public void setLimitType(int limitType)
limitType
- the limitType to setpublic boolean isBandwidthDetection()
public void setBandwidthDetection(boolean bandwidthDetection)
bandwidthDetection
- the bandwidthDetection to setpublic boolean isReaderIdle()
isReaderIdle
in class BaseConnection
public boolean isWriterIdle()
isWriterIdle
in class BaseConnection
public long getPendingMessages()
getPendingMessages
in interface IConnection
getPendingMessages
in interface RTMPMinaConnectionMXBean
getPendingMessages
in class BaseConnection
public long getReadBytes()
getReadBytes
in interface IConnection
getReadBytes
in interface RTMPMinaConnectionMXBean
getReadBytes
in class RTMPConnection
public long getWrittenBytes()
getWrittenBytes
in interface IConnection
getWrittenBytes
in interface RTMPMinaConnectionMXBean
getWrittenBytes
in class RTMPConnection
public void invokeMethod(String method)
invokeMethod
in interface RTMPMinaConnectionMXBean
public boolean isConnected()
isConnected
in interface IConnection
isConnected
in interface RTMPMinaConnectionMXBean
isConnected
in class BaseConnection
protected void onInactive()
onInactive
in class RTMPConnection
public void setIoSession(IoSession protocolSession)
protocolSession
- Protocol sessionpublic void write(Packet out)
write
in class RTMPConnection
out
- Packetpublic void writeRaw(IoBuffer out)
writeRaw
in class RTMPConnection
out
- IoBufferprotected void registerJMX()
protected void unregisterJMX()
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |