PWLib  1.10.10
Classes | Public Types | Public Member Functions | Static Public Member Functions | Protected Member Functions | Protected Attributes | Friends
PHTTPServiceProcess Class Reference

#include <httpsvc.h>

Inheritance diagram for PHTTPServiceProcess:
PServiceProcess PProcess PThread PObject PSecureHTTPServiceProcess

List of all members.

Classes

struct  Info

Public Types

enum  { MaxSecuredKeys = 10 }

Public Member Functions

 PHTTPServiceProcess (const Info &inf)
 ~PHTTPServiceProcess ()
BOOL OnStart ()
void OnStop ()
BOOL OnPause ()
void OnContinue ()
const char * GetServiceDependencies () const
virtual void OnConfigChanged ()=0
virtual BOOL Initialise (const char *initMsg)=0
BOOL ListenForHTTP (WORD port, PSocket::Reusability reuse=PSocket::CanReuseAddress, PINDEX stackSize=0x4000)
BOOL ListenForHTTP (PSocket *listener, PSocket::Reusability reuse=PSocket::CanReuseAddress, PINDEX stackSize=0x4000)
virtual PString GetPageGraphic ()
void GetPageHeader (PHTML &)
void GetPageHeader (PHTML &, const PString &title)
virtual PString GetCopyrightText ()
const PStringGetMacroKeyword () const
const PTimeGetCompilationDate () const
const PStringGetHomePage () const
const PStringGetEMailAddress () const
const PStringGetProductName () const
const PTEACypher::KeyGetProductKey () const
const PStringArrayGetSecuredKeys () const
const PTEACypher::KeyGetSignatureKey () const
BOOL ShouldIgnoreSignatures () const
void SetIgnoreSignatures (BOOL ig)
virtual void AddRegisteredText (PHTML &html)
virtual void AddUnregisteredText (PHTML &html)
virtual BOOL SubstituteEquivalSequence (PHTTPRequest &request, const PString &, PString &)
virtual PHTTPServer * CreateHTTPServer (PTCPSocket &socket)
virtual PHTTPServer * OnCreateHTTPServer (const PHTTPSpace &urlSpace)
PTCPSocketAcceptHTTP ()
BOOL ProcessHTTP (PTCPSocket &socket)

Static Public Member Functions

static PHTTPServiceProcessCurrent ()

Protected Member Functions

void ShutdownListener ()
void BeginRestartSystem ()
void CompleteRestartSystem ()
 PLIST (ThreadList, PHTTPServiceThread)

Protected Attributes

PSockethttpListeningSocket
PHTTPSpace httpNameSpace
PString macroKeyword
PTEACypher::Key productKey
PStringArray securedKeys
PTEACypher::Key signatureKey
BOOL ignoreSignatures
PTime compilationDate
PString manufacturersHomePage
PString manufacturersEmail
PString productNameHTML
PString gifHTML
PString copyrightHolder
PString copyrightHomePage
PString copyrightEmail
PThreadrestartThread
ThreadList httpThreads
PMutex httpThreadsMutex

Friends

class PConfigPage
class PConfigSectionsPage
class PHTTPServiceThread

Member Enumeration Documentation

anonymous enum
Enumerator:
MaxSecuredKeys 

Constructor & Destructor Documentation


Member Function Documentation

virtual void PHTTPServiceProcess::AddRegisteredText ( PHTML html) [virtual]
virtual void PHTTPServiceProcess::AddUnregisteredText ( PHTML html) [virtual]
virtual PHTTPServer* PHTTPServiceProcess::CreateHTTPServer ( PTCPSocket socket) [virtual]

Reimplemented in PSecureHTTPServiceProcess.

Get the current service process object.

Returns:
Pointer to service process.

Reimplemented from PServiceProcess.

References compilationDate.

const PString& PHTTPServiceProcess::GetEMailAddress ( ) const [inline]

References manufacturersEmail.

const PString& PHTTPServiceProcess::GetHomePage ( ) const [inline]

References manufacturersHomePage.

const PString& PHTTPServiceProcess::GetMacroKeyword ( ) const [inline]

References macroKeyword.

void PHTTPServiceProcess::GetPageHeader ( PHTML ,
const PString title 
)

References productKey.

const PString& PHTTPServiceProcess::GetProductName ( ) const [inline]

References productNameHTML.

References securedKeys.

References signatureKey.

virtual BOOL PHTTPServiceProcess::Initialise ( const char *  initMsg) [pure virtual]
BOOL PHTTPServiceProcess::ListenForHTTP ( WORD  port,
PSocket::Reusability  reuse = PSocket::CanReuseAddress,
PINDEX  stackSize = 0x4000 
)
BOOL PHTTPServiceProcess::ListenForHTTP ( PSocket listener,
PSocket::Reusability  reuse = PSocket::CanReuseAddress,
PINDEX  stackSize = 0x4000 
)
virtual void PHTTPServiceProcess::OnConfigChanged ( ) [pure virtual]
void PHTTPServiceProcess::OnContinue ( ) [virtual]

Resume after the service was paused.

Reimplemented from PServiceProcess.

virtual PHTTPServer* PHTTPServiceProcess::OnCreateHTTPServer ( const PHTTPSpace &  urlSpace) [virtual]
BOOL PHTTPServiceProcess::OnPause ( ) [virtual]

Called by the system when the service is to be paused. This will suspend any actions that the service may be executing. Usually this is less expensive in resource allocation etc than stopping and starting the service.

Returns:
TRUE if the service was successfully paused.

Reimplemented from PServiceProcess.

BOOL PHTTPServiceProcess::OnStart ( ) [virtual]

Called when the service is started. This typically initialises the service and returns TRUE if the service is ready to run. The Main()# function is then executed.

Returns:
TRUE if service may start, FALSE if an initialisation failure occurred.

Implements PServiceProcess.

void PHTTPServiceProcess::OnStop ( ) [virtual]

Called by the system when the service is stopped. One return from this function there is no guarentee that any more user code will be executed. Any cleaning up or closing of resource must be done in here.

Reimplemented from PServiceProcess.

PHTTPServiceProcess::PLIST ( ThreadList  ,
PHTTPServiceThread   
) [protected]
void PHTTPServiceProcess::SetIgnoreSignatures ( BOOL  ig) [inline]

References ignoreSignatures.

References ignoreSignatures.

virtual BOOL PHTTPServiceProcess::SubstituteEquivalSequence ( PHTTPRequest &  request,
const PString ,
PString  
) [virtual]

Friends And Related Function Documentation

friend class PConfigPage [friend]
friend class PConfigSectionsPage [friend]
friend class PHTTPServiceThread [friend]

Member Data Documentation

Referenced by GetCompilationDate().

PHTTPSpace PHTTPServiceProcess::httpNameSpace [protected]
ThreadList PHTTPServiceProcess::httpThreads [protected]

Referenced by GetMacroKeyword().

Referenced by GetEMailAddress().

Referenced by GetHomePage().

Referenced by GetProductKey().

Referenced by GetProductName().

Referenced by GetSecuredKeys().

Referenced by GetSignatureKey().


The documentation for this class was generated from the following file: