hotspotfw/internetconnectivitytestservice/inc/ictshttphandler.h
branchRCL_3
changeset 18 aaabc7526ded
parent 0 56b72877c1cb
--- a/hotspotfw/internetconnectivitytestservice/inc/ictshttphandler.h	Tue May 25 13:53:32 2010 +0300
+++ b/hotspotfw/internetconnectivitytestservice/inc/ictshttphandler.h	Wed Jun 09 10:53:40 2010 +0300
@@ -11,7 +11,7 @@
 *
 * Contributors:
 *
-* Description:   Contains implementation for HTTP::HEAD test
+* Description:   Contains implementation for connectivity test with HTTP
 *
 */
 
@@ -31,12 +31,12 @@
 /**
  *  Handles HTTP related things.
  *
- *  Sends HTTP::HEAD and interact with HTTP FW. Returns results to 
- *  caller.
+ *  Sends HTTP GET using HTTP FW. Returns results to the caller.
  *
  *  @lib ictsclientinterface.lib
  */
-class CIctsHttpHandler : public CTimer, public MHTTPTransactionCallback 
+class CIctsHttpHandler : public CTimer, 
+                         public MHTTPTransactionCallback
     {
     
     public:
@@ -53,7 +53,7 @@
         virtual ~CIctsHttpHandler();
     
         /**
-        * Send HTTP::HEAD request 
+        * Send HTTP GET request 
         *
         * @param aIPAddress IP address
         * @param aIapID IAP id
@@ -61,11 +61,11 @@
         * @return KErrNone if successful
         */
         TInt SendHttpRequestL( TDesC8& aIPAddress, 
-                            TUint32 aIapID, 
-                             TUint32 aNetworkId );
+                                 TUint32 aIapID, 
+                                   TUint32 aNetworkId );
         
         /**
-        * Cancels HTTP::HEAD request 
+        * Cancels HTTP GET request 
         *
         * @return None
         */
@@ -94,7 +94,6 @@
         virtual TInt MHFRunError( TInt aError, 
                                     RHTTPTransaction aTransaction, 
                                       const THTTPEvent& aEvent);
-    
 
     protected:  // Functions from base classes
         
@@ -126,7 +125,7 @@
         * @return None
         */
         void SetHttpConnectionInfoL( RConnection& aConnection, 
-                                     RSocketServ& aSocketServ );
+                                       RSocketServ& aSocketServ );
         /**
         * Send HTTP request 
         *
@@ -142,6 +141,14 @@
         * @return ETrue if found, else EFalse
         */ 
         TBool CheckHttp( TDesC8& aIPAddress );
+
+        /**
+        * Checks if HTTP status code is a redirect (301,302,303,307)
+        *
+        * @param aTransaction HTTP transactionL
+        * @return ETrue if found, else EFalse
+        */
+        TBool CheckStatusCodeL( RHTTPTransaction aTransaction );
     
     private: // data