Package com.wowza.wms.websocket.model
Class WebSocketContext
- Object
-
- com.wowza.wms.websocket.model.WebSocketContext
-
public class WebSocketContext extends Object
-
-
Field Summary
Fields Modifier and Type Field Description static int
DEFAULT_IDLEFREQUENCY
static boolean
DEFAULT_MASKOUTGOINGMESSAGES
static int
DEFAULT_MAXIMUMPENDINGWRITEBYTES
static long
DEFAULT_MAXMESSAGESIZE
static long
DEFAULT_PACKETFRAGMENTATIONSIZE
static int
DEFAULT_PINGTIMEOUT
static int
DEFAULT_VALIDATIONFREQUENCY
-
Constructor Summary
Constructors Constructor Description WebSocketContext()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description int
getIdleFrequency()
Get time in milliseconds between idle eventslong
getMaximumMessageSize()
Get the maximum WebSocket message size for a single message (0 = no limit)int
getMaximumPendingWriteBytes()
Get the number of bytes that can be pending waiting to be sent before messages are no longer send (0 turns off this feature)long
getPacketFragmentationSize()
Not being used currentlyint
getPingTimeout()
Get the timeout (milliseconds) that we wait for a response (pong) to a ping messageint
getValidationFrequency()
Get time in milliseconds between validation messages (ping from server to client).boolean
isMaskOutgoingMessages()
Should outgoing messages be masked (many browsers do not support masked outgoing messages)void
setIdleFrequency(int idleFrequency)
Set time in milliseconds between idle eventsvoid
setMaskOutgoingMessages(boolean maskOutgoingMessages)
Should outgoing messages be masked (many browsers do not support masked outgoing messages)void
setMaximumMessageSize(long maxMessageSize)
Set the maximum WebSocket message size for a single message (0 = no limit)void
setMaximumPendingWriteBytes(int maximumPendingWriteBytes)
Set the number of bytes that can be pending waiting to be sent before messages are no longer send (0 turns off this feature)void
setPacketFragmentationSize(long packetFragmentationSize)
Not being used currentlyvoid
setPingTimeout(int pingTimeout)
Set the timeout (milliseconds) that we wait for a response (pong) to a ping messagevoid
setValidationFrequency(int validationFrequency)
Set time in milliseconds between validation messages (ping from server to client).
-
-
-
Field Detail
-
DEFAULT_MAXMESSAGESIZE
public static final long DEFAULT_MAXMESSAGESIZE
- See Also:
- Constant Field Values
-
DEFAULT_PACKETFRAGMENTATIONSIZE
public static final long DEFAULT_PACKETFRAGMENTATIONSIZE
- See Also:
- Constant Field Values
-
DEFAULT_IDLEFREQUENCY
public static final int DEFAULT_IDLEFREQUENCY
- See Also:
- Constant Field Values
-
DEFAULT_VALIDATIONFREQUENCY
public static final int DEFAULT_VALIDATIONFREQUENCY
- See Also:
- Constant Field Values
-
DEFAULT_MASKOUTGOINGMESSAGES
public static final boolean DEFAULT_MASKOUTGOINGMESSAGES
- See Also:
- Constant Field Values
-
DEFAULT_MAXIMUMPENDINGWRITEBYTES
public static final int DEFAULT_MAXIMUMPENDINGWRITEBYTES
- See Also:
- Constant Field Values
-
DEFAULT_PINGTIMEOUT
public static final int DEFAULT_PINGTIMEOUT
- See Also:
- Constant Field Values
-
-
Method Detail
-
getMaximumMessageSize
public long getMaximumMessageSize()
Get the maximum WebSocket message size for a single message (0 = no limit)- Returns:
- maximum WebSocket message size
-
setMaximumMessageSize
public void setMaximumMessageSize(long maxMessageSize)
Set the maximum WebSocket message size for a single message (0 = no limit)- Parameters:
maxMessageSize
- maximum WebSocket message size
-
isMaskOutgoingMessages
public boolean isMaskOutgoingMessages()
Should outgoing messages be masked (many browsers do not support masked outgoing messages)- Returns:
- true, if messages are masked
-
setMaskOutgoingMessages
public void setMaskOutgoingMessages(boolean maskOutgoingMessages)
Should outgoing messages be masked (many browsers do not support masked outgoing messages)- Parameters:
maskOutgoingMessages
- true, if messages are masked
-
getIdleFrequency
public int getIdleFrequency()
Get time in milliseconds between idle events- Returns:
- idle time (milliseconds)
-
setIdleFrequency
public void setIdleFrequency(int idleFrequency)
Set time in milliseconds between idle events- Parameters:
idleFrequency
- idle time (milliseconds)
-
getPacketFragmentationSize
public long getPacketFragmentationSize()
Not being used currently- Returns:
- not being used
-
setPacketFragmentationSize
public void setPacketFragmentationSize(long packetFragmentationSize)
Not being used currently- Parameters:
packetFragmentationSize
- not being used
-
getValidationFrequency
public int getValidationFrequency()
Get time in milliseconds between validation messages (ping from server to client). Value of zero turns off validation.- Returns:
- validation time (milliseconds)
-
setValidationFrequency
public void setValidationFrequency(int validationFrequency)
Set time in milliseconds between validation messages (ping from server to client). Value of zero turns off validation.- Parameters:
validationFrequency
- validation time (milliseconds)
-
getMaximumPendingWriteBytes
public int getMaximumPendingWriteBytes()
Get the number of bytes that can be pending waiting to be sent before messages are no longer send (0 turns off this feature)- Returns:
- number of bytes that can be pending waiting
-
setMaximumPendingWriteBytes
public void setMaximumPendingWriteBytes(int maximumPendingWriteBytes)
Set the number of bytes that can be pending waiting to be sent before messages are no longer send (0 turns off this feature)- Parameters:
maximumPendingWriteBytes
- number of bytes that can be pending waiting
-
getPingTimeout
public int getPingTimeout()
Get the timeout (milliseconds) that we wait for a response (pong) to a ping message- Returns:
- timeout (milliseconds)
-
setPingTimeout
public void setPingTimeout(int pingTimeout)
Set the timeout (milliseconds) that we wait for a response (pong) to a ping message- Parameters:
pingTimeout
- timeout (milliseconds)
-
-