browserchannel.js
No description.

File Location

/goog/net/browserchannel.js

Classes

goog.net.BrowserChannel
Encapsulates the logic for a single BrowserChannel.
goog.net.BrowserChannel.Handler
Abstract base class for the browser channel handler
goog.net.BrowserChannel.QueuedMap
Simple container class for a (mapId, map) pair.
goog.net.BrowserChannel.ServerReachabilityEvent
Event class for goog.net.BrowserChannel.Event.SERVER_REACHABILITY_EVENT.
goog.net.BrowserChannel.StatEvent
Event class for goog.net.BrowserChannel.Event.STAT_EVENT
goog.net.BrowserChannel.TimingEvent
Event class for goog.net.BrowserChannel.Event.TIMING_EVENT

Public Protected Private

Enumerations

Global Functions

goog.net.BrowserChannel.createChannelRequest(channelchannelDebugopt_sessionIdopt_requestIdopt_retryId) !goog.net.ChannelRequest
Instantiates a ChannelRequest with the given parameters. Overidden in tests.
Arguments:
channel : goog.net.BrowserChannel | goog.net.BrowserTestChannel
The BrowserChannel that owns this request.
channelDebug : goog.net.ChannelDebug
A ChannelDebug to use for logging.
opt_sessionId : string=
The session id for the channel.
opt_requestId : string | number=
The request id for this request.
opt_retryId : number=
The retry id for this request.
Returns: !goog.net.ChannelRequest  The created channel request.
code »
function%39&fn()
No description.
code »
goog.net.BrowserChannel.getStatEventTarget() goog.events.EventTarget
Returns the singleton event target for stat events.
Returns: goog.events.EventTarget  The event target for stat events.
code »
goog.net.BrowserChannel.isFatalError_(errorstatusCode) boolean
Returns whether or not the given error/status combination is fatal or not. On fatal errors we immediately close the session rather than retrying the failed request.
Arguments:
error : ?goog.net.ChannelRequest.Error
The error code for the failed request.
statusCode : number
The last HTTP status code.
Returns: boolean  Whether or not the error is fatal.
code »
goog.net.BrowserChannel.notifyStatEvent(stat)
Helper function to call the stat event callback.
Arguments:
stat : goog.net.BrowserChannel.Stat
The stat.
code »
goog.net.BrowserChannel.notifyTimingEvent(sizerttretries)
Helper function to notify listeners about POST request performance.
Arguments:
size : number
Number of characters in the POST data.
rtt : number
The amount of time from POST start to response.
retries : number
The number of times the POST had to be retried.
code »
goog.net.BrowserChannel.onEndExecution()
Helper function to call the end hook
code »
goog.net.BrowserChannel.onStartExecution()
Helper function to call the start hook
code »
goog.net.BrowserChannel.setEndThreadExecutionHook(endHook)
Allows the application to set an execution hooks for when BrowserChannel stops processing requests. This is useful to track timing or logging special information. The function takes no parameters and return void.
Arguments:
endHook : Function
The function for the end hook.
code »
goog.net.BrowserChannel.setStartThreadExecutionHook(startHook)
Allows the application to set an execution hooks for when BrowserChannel starts processing requests. This is useful to track timing or logging special information. The function takes no parameters and return void.
Arguments:
startHook : Function
The function for the start hook.
code »
goog.net.BrowserChannel.setTimeout(fnms) number
Wrapper around SafeTimeout which calls the start and end execution hooks with a try...finally block.
Arguments:
fn : Function
The callback function.
ms : number
The time in MS for the timer.
Returns: number  The ID of the timer.
code »

Global Variables

function%38 :
No description.
Code »
function%39 :
No description.
Code »
function%40 :
No description.
Code »
function%41 :
No description.
Code »
function%42 :
No description.
Code »

Directory net

File Reference