|
Project Wonder 5.0 | |||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||||
java.lang.Objectcom.webobjects.appserver.WORequestHandler
er.ajax.AjaxPushRequestHandler
public class AjaxPushRequestHandler
Request handler that offers push-style notifications.
Gets registered under "/push/" on framework load.
You should open an Ajax.Request, implement onInteractive: and the do
something useful when you get new data. Changes should be pushed with
push(sessionID, someString);
TODO:
| Field Summary | |
|---|---|
static String |
AjaxCometRequestHandlerKey
|
protected static Logger |
log
|
| Fields inherited from class com.webobjects.appserver.WORequestHandler |
|---|
DidHandleRequestNotification |
| Constructor Summary | |
|---|---|
AjaxPushRequestHandler()
|
|
| Method Summary | |
|---|---|
WOResponse |
handleRequest(WORequest request)
Get/Create the current request for the session and return it. |
static boolean |
isResponseOpen(String sessionID,
String name)
Returns whether or not there is a response open for the given session id and name. |
static void |
push(String sessionID,
String name,
NSData message)
Push a data message to the client. |
static void |
push(String sessionID,
String name,
String message)
Push a string message to the client. |
void |
sessionDidTimeOut(NSNotification n)
Remove stale responses when a session times out. |
static void |
stop(String sessionID,
String name)
Push a string message to the client. |
| Methods inherited from class com.webobjects.appserver.WORequestHandler |
|---|
toString |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Field Detail |
|---|
public static final String AjaxCometRequestHandlerKey
protected static Logger log
| Constructor Detail |
|---|
public AjaxPushRequestHandler()
| Method Detail |
|---|
public void sessionDidTimeOut(NSNotification n)
n - the session timeout notificationpublic WOResponse handleRequest(WORequest request)
handleRequest in class WORequestHandlerrequest - the requestpublic static boolean isResponseOpen(String sessionID, String name)
sessionID - the session id of the push responsename - the name of the push response
public static void stop(String sessionID, String name)
sessionID - the session id of the push responsename - the name of the push responsepublic static void push(String sessionID, String name, String message)
sessionID - the session id of the push responsename - the name of the push responsemessage - the message to pushpublic static void push(String sessionID, String name, NSData message)
sessionID - the session id of the push responsename - the name of the push responsemessage - the message to push
|
Last updated: Wed, Feb 22, 2012 07:00 AM EST | |||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||||