Daraja HTTP Framework 3.0.7-SNAPSHOT
HTTP server framework for Object Pascal
Loading...
Searching...
No Matches
TdjAbstractHandler Class Reference

Interface for HTTP request handlers. More...

Inheritance diagram for TdjAbstractHandler:
TdjLifeCycle IHandler ILifeCycle TdjAbstractHandlerContainer TdjWebComponentHandler TdjHandlerCollection TdjHandlerWrapper TdjHandlerList TdjContextHandler TdjServerBase TdjContextHandlerCollection TdjWebComponentContextHandler TdjServer TdjWebAppContext

Public Member Functions

 TdjAbstractHandler ()
 Constructor.
Boolean IsStarted ()
Boolean IsStopped ()
 Start ()
 Starts the component.
 Stop ()
 Stops the component.

Public Attributes

Boolean Started
Boolean Stopped

Protected Member Functions

 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.

Detailed Description

Interface for HTTP request handlers.

Constructor & Destructor Documentation

◆ TdjAbstractHandler()

TdjAbstractHandler::TdjAbstractHandler ( )

Constructor.

References TdjAbstractHandler().

Referenced by TdjAbstractHandler().

Member Function Documentation

◆ CheckStarted()

TdjLifeCycle::CheckStarted ( )
protectedinherited

Raises an exception if the lifecycle is in "started" state.

References TdjLifeCycle().

◆ CheckStopped()

TdjLifeCycle::CheckStopped ( )
protectedinherited

Raises an exception if the lifecycle is in "stopped" state.

References TdjLifeCycle(), and Started.

◆ Handle()

TdjAbstractHandler::Handle ( const string Target,
TdjServerContext Context,
TdjRequest Request,
TdjResponse Response )
protected

Handles an HTTP request.

Parameters
TargetTarget path or resource identifier
ContextServer context for this request
RequestHTTP request object
ResponseHTTP response object to populate
Exceptions
EWebComponentExceptionif an exception occurs that interferes with the component's normal operation.

Implements IHandler.

◆ IsStarted()

Boolean TdjLifeCycle::IsStarted ( )
inherited
Returns
True if component is started

Implements ILifeCycle.

References Create().

Referenced by DoStart(), and TdjWebComponentHandler::FindHolder().

◆ IsStopped()

Boolean TdjLifeCycle::IsStopped ( )
inherited
Returns
True if component is stopped

Implements ILifeCycle.

Referenced by DoStart().

◆ Start()

TdjLifeCycle::Start ( )
inherited

Starts the component.

Implements ILifeCycle.

References Stopped.

◆ Stop()

TdjLifeCycle::Stop ( )
inherited

Stops the component.

Implements ILifeCycle.

References TdjLifeCycle().

Referenced by DoStart(), and TdjWebComponentHandler::InvokeService().

Member Data Documentation

◆ Started

◆ Stopped

Boolean TdjLifeCycle::Stopped
inherited

Referenced by DoStop(), and Start().