public final class SpdySession extends Object
| Modifier and Type | Class and Description |
|---|---|
class |
SpdySession.BidirectionalBuilder |
class |
SpdySession.StreamBuilder |
class |
SpdySession.UnidirectionalBuilder |
| Constructor and Description |
|---|
SpdySession(Connection<?> connection,
boolean isServer,
SpdyHandlerFilter handlerFilter) |
| Modifier and Type | Method and Description |
|---|---|
static void |
bind(Connection connection,
SpdySession spdySession) |
static SpdySession |
get(Connection connection) |
Connection |
getConnection() |
int |
getDeflaterCompressionLevel() |
int |
getLocalInitialWindowSize() |
int |
getLocalMaxConcurrentStreams()
Returns the maximum number of concurrent streams allowed for this session by our side.
|
MemoryManager |
getMemoryManager() |
ReentrantLock |
getNewClientStreamLock() |
int |
getNextLocalStreamId() |
int |
getPeerInitialWindowSize() |
int |
getPeerMaxConcurrentStreams()
Returns the maximum number of concurrent streams allowed for this session by peer.
|
SpdyStream |
getStream(int streamId) |
SpdySession.StreamBuilder |
getStreamBuilder() |
void |
goAway(int statusCode)
If the session is still open - closes it and sends GOAWAY frame to a peer,
otherwise if the session was already closed - does nothing.
|
boolean |
isServer() |
SpdyStream |
openStream(HttpRequestPacket spdyRequest,
int streamId,
int associatedToStreamId,
int priority,
int slot,
boolean isUnidirectional,
boolean fin)
Method is not thread-safe, it is expected that it will be called
within
getNewClientStreamLock() lock scope. |
void |
setDeflaterCompressionLevel(int deflaterCompressionLevel) |
void |
setLocalInitialWindowSize(int localInitialWindowSize) |
void |
setLocalMaxConcurrentStreams(int localMaxConcurrentStreams)
Sets the default maximum number of concurrent streams allowed for this session by our side.
|
public SpdySession(Connection<?> connection, boolean isServer, SpdyHandlerFilter handlerFilter)
public static SpdySession get(Connection connection)
public static void bind(Connection connection, SpdySession spdySession)
public SpdySession.StreamBuilder getStreamBuilder()
public int getPeerInitialWindowSize()
public int getLocalInitialWindowSize()
public void setLocalInitialWindowSize(int localInitialWindowSize)
public int getLocalMaxConcurrentStreams()
public void setLocalMaxConcurrentStreams(int localMaxConcurrentStreams)
public int getPeerMaxConcurrentStreams()
public int getNextLocalStreamId()
public Connection getConnection()
public MemoryManager getMemoryManager()
public boolean isServer()
public SpdyStream getStream(int streamId)
public void goAway(int statusCode)
statusCode - GOAWAY status code.public int getDeflaterCompressionLevel()
public void setDeflaterCompressionLevel(int deflaterCompressionLevel)
public ReentrantLock getNewClientStreamLock()
public SpdyStream openStream(HttpRequestPacket spdyRequest, int streamId, int associatedToStreamId, int priority, int slot, boolean isUnidirectional, boolean fin) throws SpdyStreamException
getNewClientStreamLock() lock scope.
The caller code is responsible for obtaining and releasing the mentioned
getNewClientStreamLock() lock.SpdyStreamExceptionCopyright © 2013 Oracle Corporation. All Rights Reserved.