Nebula
Loading...
Searching...
No Matches
Http::HttpRequest Class Reference

#include <httprequest.h>

Detailed Description

Encapsulates a complete Http request into a message.

Inherits Messaging::Message.

Public Member Functions

 HttpRequest ()
 constructor
 
virtual ~HttpRequest ()
 destructor
 
void SetMethod (HttpMethod::Code requestMethod)
 set the Http method (GET, PUT, etc...)
 
HttpMethod::Code GetMethod () const
 get the Http method
 
void SetURI (const IO::URI &requestUri)
 set the request URI
 
const IO::URIGetURI () const
 get the request URI
 
void SetResponseContentStream (const Ptr< IO::Stream > &responseContentStream)
 set the response content stream
 
const Ptr< IO::Stream > & GetResponseContentStream () const
 get the response content stream
 
void SetStatus (HttpStatus::Code status)
 set the http status (set by HttpRequestHandler)
 
HttpStatus::Code GetStatus () const
 get the http status
 
- Public Member Functions inherited from Messaging::Message
 Message ()
 constructor
 
bool CheckId (const Messaging::Id &id) const
 return true if message is of the given id
 
virtual void Encode (const Ptr< IO::BinaryWriter > &writer)
 encode message into a stream
 
virtual void Decode (const Ptr< IO::BinaryReader > &reader)
 decode message from a stream
 
void SetHandled (bool b)
 set the handled flag
 
bool Handled () const
 return true if the message has been handled
 
void SetDeferred (bool b)
 set deferred flag
 
bool IsDeferred () const
 get deferred flag
 
void SetDeferredHandled (bool b)
 set the deferred handled flag
 
bool DeferredHandled () const
 get the deferred handled flag
 
bool GetDistribute () const
 should this message be distributed over the network
 
void SetDistribute (bool b)
 enable distribution over network
 
- Public Member Functions inherited from Core::RefCounted
 RefCounted ()
 constructor
 
int GetRefCount () const
 get the current refcount
 
void AddRef ()
 increment refcount by one
 
void Release ()
 decrement refcount and destroy object if refcount is zero
 
bool IsInstanceOf (const Rtti &rtti) const
 return true if this object is instance of given class
 
bool IsInstanceOf (const Util::String &className) const
 return true if this object is instance of given class by string
 
bool IsInstanceOf (const Util::FourCC &classFourCC) const
 return true if this object is instance of given class by fourcc
 
bool IsA (const Rtti &rtti) const
 return true if this object is instance of given class, or a derived class
 
bool IsA (const Util::String &rttiName) const
 return true if this object is instance of given class, or a derived class, by string
 
bool IsA (const Util::FourCC &rttiFourCC) const
 return true if this object is instance of given class, or a derived class, by fourcc
 
const Util::StringGetClassName () const
 get the class name
 
Util::FourCC GetClassFourCC () const
 get the class FourCC code
 

Private Member Functions

 __DeclareClass (HttpRequest)
 

Private Attributes

 __DeclareMsgId
 
HttpMethod::Code method
 
IO::URI uri
 
Ptr< IO::StreamresponseContentStream
 
HttpStatus::Code status
 

Additional Inherited Members

- Static Public Member Functions inherited from Core::RefCounted
static void DumpRefCountingLeaks ()
 dump refcounting leaks, call at end of application (NEBULA_DEBUG builds only!)
 
- Protected Member Functions inherited from Core::RefCounted
virtual ~RefCounted ()
 destructor (called when refcount reaches zero)
 
- Protected Attributes inherited from Messaging::Message
volatile int handled
 
bool deferred
 
bool deferredHandled
 
bool distribute
 

Constructor & Destructor Documentation

◆ HttpRequest()

Http::HttpRequest::HttpRequest ( )

constructor

◆ ~HttpRequest()

Http::HttpRequest::~HttpRequest ( )
virtual

destructor

Member Function Documentation

◆ __DeclareClass()

Http::HttpRequest::__DeclareClass ( HttpRequest )
private

◆ GetMethod()

HttpMethod::Code Http::HttpRequest::GetMethod ( ) const
inline

get the Http method

◆ GetResponseContentStream()

const Ptr< IO::Stream > & Http::HttpRequest::GetResponseContentStream ( ) const
inline

get the response content stream

◆ GetStatus()

HttpStatus::Code Http::HttpRequest::GetStatus ( ) const
inline

get the http status

◆ GetURI()

const IO::URI & Http::HttpRequest::GetURI ( ) const
inline

get the request URI

◆ SetMethod()

void Http::HttpRequest::SetMethod ( HttpMethod::Code requestMethod)
inline

set the Http method (GET, PUT, etc...)

◆ SetResponseContentStream()

void Http::HttpRequest::SetResponseContentStream ( const Ptr< IO::Stream > & responseContentStream)
inline

set the response content stream

◆ SetStatus()

void Http::HttpRequest::SetStatus ( HttpStatus::Code status)
inline

set the http status (set by HttpRequestHandler)

◆ SetURI()

void Http::HttpRequest::SetURI ( const IO::URI & requestUri)
inline

set the request URI

Member Data Documentation

◆ __DeclareMsgId

Http::HttpRequest::__DeclareMsgId
private

◆ method

HttpMethod::Code Http::HttpRequest::method
private

◆ responseContentStream

Ptr<IO::Stream> Http::HttpRequest::responseContentStream
private

◆ status

HttpStatus::Code Http::HttpRequest::status
private

◆ uri

IO::URI Http::HttpRequest::uri
private

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