#include <mw/http/rhttpsession.h>
Link against: http.lib
class RHTTPSession |
A session handle. A session is a set of HTTP transactions using the same connection settings (e.g. proxy) and the same set of filters. Multi-homing support provided by HTTP framework enables clients to specify Connection preferences through the session property EHttpSocketConnection.
Note that RHTTPSession (and consequently the whole of HTTP) depends on the active scheduler; a scheduler must be installed when the session is opened and it must be running if a transaction is actually to do anything.
See also: RHTTPTransaction
RHTTPSession | ( | ) | [inline] |
See also: OpenL
IMPORT_C void | Close | ( | ) |
IMPORT_C void | ConnectL | ( | ) |
Connect this WSP session. This function does nothing when called for text-mode.
IMPORT_C RHTTPConnectionInfo | ConnectionInfo | ( | ) | const |
Accessor for the connection info for this session, and which is used for all transactions in the session. Note that by and large, the connection info should be set up before the first transaction is created.
IMPORT_C void | DisconnectL | ( | ) |
Disconnect this WSP session. This function does nothing when called for text-mode.
IMPORT_C void | FailSessionEvent | ( | THTTPFilterHandle | aStart = THTTPFilterHandle::EClient | ) |
Fail the session event
RHTTPFilterCollection | FilterCollection | ( | ) | const [inline] |
Accessor for the filter collection. Note that the filter collection can't be edited after the first transaction has been created.
IMPORT_C const TStringTable & | GetTable | ( | ) | [static] |
IMPORT_C MHttpDataOptimiser * | HttpDataOptimiser | ( | ) |
Returns the object of the MHttpDataOptimiser implementation class.
IMPORT_C void | ListAvailableProtocolsL | ( | RPointerArray< HBufC8 > & | aProtocolArray | ) | [static] |
This is a static methods that lists all the available protocols by adding the prorocol descriptors to the descriptor array passed in. Any existing data in the descriptor array passed in is deleted. This function leaves if the descriptor array can not be updated with the appropriate array code.
See also: OpenL
Parameters | |
---|---|
aProtocolArray | A pointer array to heap based descriptors. The data in this array will be deleted and filled with descriptors containing the available protocols |
IMPORT_C void | OpenL | ( | ) |
IMPORT_C void | OpenL | ( | const TDesC8 & | aProtocol | ) |
Parameters | |
---|---|
aProtocol | The protocol required |
IMPORT_C void | OpenL | ( | const TDesC8 & | aProtocol, |
MHTTPFilterCreationCallback * | aSessionCallback | |||
) |
Parameters | |
---|---|
aProtocol | The protocol required |
aSessionCallback | The pointer to the object providing the call back method |
IMPORT_C RHTTPTransaction | OpenTransactionL | ( | const TUriC8 & | aURI, |
MHTTPTransactionCallback & | aCallback, | |||
RStringF | aMethod = RStringF() | |||
) |
Parameters | |
---|---|
aURI | The URI that the request will be sent to. |
aCallback | A callback for all status events relating to this transaction. |
aMethod | The HTTP method to use (default: GET) |
Leave Codes | |
---|---|
KErrNoMemory | There was not enough memory. |
IMPORT_C RHTTPHeaders | RequestSessionHeadersL | ( | ) |
Accessor for the session headers. These are headers that will get added to each request They only become part of the transaction headers when a transaction is submitted and they will not replace headers that already exist in the transaction request
IMPORT_C RHTTPHeaders | ResponseSessionHeadersL | ( | ) |
Accessor for the response session headers. These are headers that will get added to each response if the corresponding header doesn't already exist
IMPORT_C void | SendSessionEventL | ( | THTTPSessionEvent | aStatus, |
THTTPSessionEvent::TDirection | aDirection, | |||
THTTPFilterHandle | aStart = THTTPFilterHandle::EClient | |||
) |
Send an session event
IMPORT_C TInt | ServerCert | ( | TCertInfo & | aServerCert | ) |
Obtain the server certificate information for this session. This function should only be used for WSP, for text-mode use RHttpTransaction::ServerCert.
See also: RHttpTransaction::ServerCert
v9.2 onwards - maintained for compatibility with v9.1 and before TCertInfo has been deprecated since v9.2. CCertificate may be used as an alternative.
Parameters | |
---|---|
aServerCert | A client supplied object into which the certificate information will be placed. |
IMPORT_C const CCertificate * | ServerCert | ( | ) |
Obtain the server certificate information for this session. This function should only be used for WSP. HTTP should use RHttpTransaction::ServerCert.
See also: RHttpSession::ServerCert
IMPORT_C void | SetSessionEventCallback | ( | MHTTPSessionEventCallback * | aSessionEventCallback | ) |
Sets the session event callback. Until it is set all incoming session events are consumed
IMPORT_C void | SetupDefaultProxyFromCommsDatL | ( | ) |
Set the default Proxy for Http Session. This function reads default proxy information,if available, from CommsDat and uses it for the current Session.
IMPORT_C void | SetupHttpDataOptimiser | ( | MHttpDataOptimiser & | aHttpOptimiser | ) |
Sets the HTTP data optimiser for the session.
Parameters | |
---|---|
aHttpOptimiser | An object of the implementation of interface, MHttpDataOptimiser, supplied by the client. |
IMPORT_C RStringPool | StringPool | ( | ) | const |
Accessor for the HTTP string pool.
TBool | operator!= | ( | RHTTPSession | aTrans | ) | const [inline] |
Inequality operator
Parameters | |
---|---|
aTrans | The session to compare this one to. |
TBool | operator== | ( | RHTTPSession | aTrans | ) | const [inline] |
Equality operator.
Parameters | |
---|---|
aTrans | The session to compare this one to. |