...
Package channel
Package channel implements the server side of App Engine's Channel API.
Create creates a new channel associated with the given clientID,
which must be unique to the client that will use the returned token.
token, err := channel.Create(c, "player1")
if err != nil {
// handle error
}
// return token to the client in an HTTP response
Send sends a message to the client over the channel identified by clientID.
channel.Send(c, "player1", "Game over!")
In the call graph viewer below, each node
is a function belonging to this package
and its children are the functions it
calls—perhaps dynamically.
The root nodes are the entry points of the
package: functions that may be called from
outside the package.
There may be non-exported or anonymous
functions among them if they are called
dynamically from another package.
Click a node to visit that function's source code.
From there you can visit its callers by
clicking its declaring func
token.
Functions may be omitted if they were
determined to be unreachable in the
particular programs or tests that were
analyzed.
func Create(c context.Context, clientID string) (token string, err error)
Create creates a channel and returns a token for use by the client.
The clientID is an application-provided string used to identify the client.
func Send(c context.Context, clientID, message string) error
Send sends a message on the channel associated with clientID.
func SendJSON(c context.Context, clientID string, value interface{}) error
SendJSON is a helper function that sends a JSON-encoded value
on the channel associated with clientID.