Class TCallbackResponseAdapter
TCallbackResponseAdapter alters the THttpResponse's outputs.
A TCallbackResponseWriter is used instead of the TTextWrite when createHtmlWriter is called. Each call to createHtmlWriter will create a new TCallbackResponseWriter. When flushContent() is called each instance of TCallbackResponseWriter's content is flushed. The callback response data can be set using the ResponseData property.
Method Summary |
void
|
Returns a new instance of THtmlWriter.
|
void
|
Flushes the contents in the writers.
|
string
|
|
mixed
|
|
void
|
Delay the redirect until we process the rest of the page.
|
void
|
|
Methods Inherited From TComponent |
TComponent::addParsedObject(), TComponent::attachEventHandler(), TComponent::canGetProperty(), TComponent::canSetProperty(), TComponent::createdOnTemplate(), TComponent::detachEventHandler(), TComponent::evaluateExpression(), TComponent::evaluateStatements(), TComponent::getEventHandlers(), TComponent::getSubProperty(), TComponent::hasEvent(), TComponent::hasEventHandler(), TComponent::hasProperty(), TComponent::raiseEvent(), TComponent::setSubProperty(), TComponent::__get(), TComponent::__set()
|
Method Details |
createNewHtmlWriter
public void createNewHtmlWriter |
(string $type , THttpResponse $response ) |
Returns a new instance of THtmlWriter.
An instance of TCallbackResponseWriter is created to hold the content.
Input |
string | $type | writer class name. |
THttpResponse | $response | http response handler. |
Output |
Exception |
|
flushContent
public void flushContent |
() |
Flushes the contents in the writers.
|
getRedirectedUrl
public string getRedirectedUrl |
() |
Output |
string
| new url for callback response to redirect to. |
Exception |
|
getResponseData
public mixed getResponseData |
() |
Output |
mixed
| callback response data. |
Exception |
|
httpRedirect
public void httpRedirect |
(string $url ) |
Delay the redirect until we process the rest of the page.
Input |
string | $url | new url to redirect to. |
Output |
Exception |
|
setResponseData
public void setResponseData |
(mixed $data ) |
Input |
mixed | $data | callback response data. |
Output |
Exception |
|
|