|
Daraja HTTP Framework 3.0.7-SNAPSHOT
HTTP server framework for Object Pascal
|
Iterates handler list and exits when the response code is set. More...
Public Member Functions | |
| TdjHandlerList () | |
| Constructor. | |
| Boolean | IsStarted () |
| Boolean | IsStopped () |
| Start () | |
| Starts the component. | |
| Stop () | |
| Stops the component. | |
Public Attributes | |
| Boolean | Started |
| Boolean | Stopped |
Protected Member Functions | |
| AddHandler (const IHandler Handler) | |
| Adds a handler to this container. | |
| CheckStarted () | |
| Raises an exception if the lifecycle is in "started" state. | |
| CheckStopped () | |
| Raises an exception if the lifecycle is in "stopped" state. | |
| Handle (const string Target, TdjServerContext Context, TdjRequest Request, TdjResponse Response) | |
| Handles an HTTP request. | |
| RemoveHandler (const IHandler Handler) | |
| Removes a handler from this container. | |
Protected Attributes | |
| TdjHandlers | FHandlers |
| The handler collection. | |
Iterates handler list and exits when the response code is set.
If the response code is still -1, it returns 404
This extension of TdjHandlerCollection will call each contained handler in turn until either an exception is thrown or a positive response status is set.
| TdjHandlerList::TdjHandlerList | ( | ) |
Constructor.
Referenced by Handle().
|
protectedinherited |
Adds a handler to this container.
| Handler | Handler to add |
Implements IHandlerContainer.
References Create().
|
protectedinherited |
Raises an exception if the lifecycle is in "started" state.
References TdjLifeCycle().
|
protectedinherited |
Raises an exception if the lifecycle is in "stopped" state.
References TdjLifeCycle(), and Started.
|
protected |
Handles an HTTP request.
| Target | Target path or resource identifier |
| Context | Server context for this request |
| Request | HTTP request object |
| Response | HTTP response object to populate |
| EWebComponentException | if an exception occurs that interferes with the component's normal operation. |
Implements IHandler.
References TdjHandlerList().
|
inherited |
Implements ILifeCycle.
References Create().
Referenced by DoStart(), and TdjWebComponentHandler::FindHolder().
|
inherited |
|
protectedinherited |
Removes a handler from this container.
| Handler | Handler to remove |
Implements IHandlerContainer.
|
inherited |
|
inherited |
Stops the component.
Implements ILifeCycle.
References TdjLifeCycle().
Referenced by DoStart(), and TdjWebComponentHandler::InvokeService().
|
protectedinherited |
The handler collection.
Referenced by TdjHandlerCollection(), and ~TdjHandlerCollection().
|
inherited |