|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.directwebremoting.extend.ScriptConduit
org.directwebremoting.dwrp.BaseScriptConduit
public abstract class BaseScriptConduit
A ScriptConduit that works with the parent Marshaller. In some ways this is nasty because it has access to essentially private parts of PollHandler, however there is nowhere sensible to store them within that class, so this is a hacky simplification.
Field Summary | |
---|---|
protected BasicAlarm |
alarm
An Alarm that goes off if something is badly broken |
protected java.lang.String |
batchId
What is the ID of the request that we are responding to? |
protected ConverterManager |
converterManager
How we convert parameters |
protected java.io.PrintWriter |
out
The PrintWriter to send output to, and that we should synchronize against |
protected HttpServletResponse |
response
Used to flush data to the output stream |
Fields inherited from class org.directwebremoting.extend.ScriptConduit |
---|
RANK_FAST, RANK_PROCEDURAL, RANK_SLOW |
Constructor Summary | |
---|---|
BaseScriptConduit(HttpServletResponse response,
java.lang.String batchId,
ConverterManager converterManager)
Simple ctor |
Method Summary | |
---|---|
protected abstract void |
beginStream()
Called when we are initially setting up the stream. |
void |
close(int timetoNextPoll)
A poll has finished, get the client to call us back |
protected abstract void |
endStream()
Called when we are shutting the stream down. |
protected boolean |
flush()
Ensure that output we have done is written to the client |
org.directwebremoting.dwrp.Alarm |
getErrorAlarm()
|
protected abstract java.lang.String |
getOutboundMimeType()
What mime type should we send to the browser for this data? |
Methods inherited from class org.directwebremoting.extend.ScriptConduit |
---|
addScript, compareTo, equals, getRank, hashCode, toString |
Methods inherited from class java.lang.Object |
---|
clone, finalize, getClass, notify, notifyAll, wait, wait, wait |
Field Detail |
---|
protected ConverterManager converterManager
protected final HttpServletResponse response
protected final java.io.PrintWriter out
protected final java.lang.String batchId
protected BasicAlarm alarm
Constructor Detail |
---|
public BaseScriptConduit(HttpServletResponse response, java.lang.String batchId, ConverterManager converterManager) throws java.io.IOException
response
- Used to flush outputbatchId
- The id of the batch that we are responding toconverterManager
- How we convert objects to script
java.io.IOException
- If stream ops failMethod Detail |
---|
protected abstract java.lang.String getOutboundMimeType()
protected abstract void beginStream()
This method is always called exactly once in the lifetime of a
conduit, after #preStreamSetup()
and before any scripts are sent.
protected abstract void endStream()
This method is always called exactly once in the lifetime of a conduit, just before the stream is closed.
public void close(int timetoNextPoll) throws java.io.IOException
timetoNextPoll
- How long before we tell the browser to come back?
java.io.IOException
protected boolean flush()
public org.directwebremoting.dwrp.Alarm getErrorAlarm()
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |