|
Daraja HTTP Framework 3.1.1-SNAPSHOT
HTTP server framework for Object Pascal
|
A collection of handlers. More...
Public Member Functions | |
| TdjHandlerCollection () | |
| Create a TdjHandlerCollection. | |
| ~TdjHandlerCollection () | |
| Destructor. | |
| Boolean | IsStarted () |
| Boolean | IsStopped () |
| SetStarted (const Boolean Value) | |
| SetStopped (const Boolean Value) | |
| Start () | |
| Starts the component. | |
| Stop () | |
| Stops the component. | |
Public Attributes | |
| TCriticalSection | CS |
| Boolean | FStopped |
| 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. | |
A collection of handlers.
For each request, all handler are called, regardless of the response status or exceptions.
| TdjHandlerCollection::TdjHandlerCollection | ( | ) |
Create a TdjHandlerCollection.
References TdjHandlerCollection(), and FHandlers.
Referenced by TdjHandlerCollection(), ~TdjHandlerCollection(), and AddHandler().
| TdjHandlerCollection::~TdjHandlerCollection | ( | ) |
Destructor.
References TdjHandlerCollection(), FHandlers, and TdjLifeCycle::Started.
|
protected |
Adds a handler to this container.
| Handler | Handler to add |
Implements IHandlerContainer.
References TdjHandlerCollection().
|
protectedinherited |
Raises an exception if the lifecycle is in "started" state.
|
protectedinherited |
Raises an exception if the lifecycle is in "stopped" state.
References TdjLifeCycle().
|
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.
|
inherited |
Implements ILifeCycle.
References TdjLifeCycle().
Referenced by DoStart(), and TdjWebComponentHandler::InvokeService().
|
inherited |
Implements ILifeCycle.
References Create().
Referenced by DoStart().
|
protected |
Removes a handler from this container.
| Handler | Handler to remove |
Implements IHandlerContainer.
References Create().
|
inherited |
Referenced by DoStop().
|
inherited |
Referenced by DoStop().
|
inherited |
|
inherited |
Stops the component.
Implements ILifeCycle.
References Stopped.
Referenced by DoStart(), and TdjWebComponentHandler::InvokeService().
|
inherited |
Referenced by ~TdjLifeCycle().
|
protected |
The handler collection.
Referenced by TdjHandlerCollection(), and ~TdjHandlerCollection().
|
inherited |
Referenced by ~TdjLifeCycle(), and DoStop().
|
inherited |
Referenced by TdjHandlerCollection::~TdjHandlerCollection(), and DoStop().