internetradio2.0/dataproviderinc/irdataproviderconstants.h
changeset 14 896e9dbc5f19
parent 12 608f67c22514
child 15 065198191975
equal deleted inserted replaced
12:608f67c22514 14:896e9dbc5f19
     1 /*
       
     2 * Copyright (c) 2006-2007 Nokia Corporation and/or its subsidiary(-ies). 
       
     3 * All rights reserved.
       
     4 * This component and the accompanying materials are made available
       
     5 * under the terms of "Eclipse Public License v1.0"
       
     6 * which accompanies this distribution, and is available
       
     7 * at the URL "http://www.eclipse.org/legal/epl-v10.html".
       
     8 *
       
     9 * Initial Contributors:
       
    10 * Nokia Corporation - initial contribution.
       
    11 *
       
    12 * Contributors:
       
    13 *
       
    14 * Description:  ?Description
       
    15 *
       
    16 */
       
    17 
       
    18 
       
    19 #ifndef IRDATAPROVIDERCONSTANTS_H
       
    20 #define IRDATAPROVIDERCONSTANTS_H
       
    21 
       
    22 #include <e32def.h>
       
    23 
       
    24 // Constants
       
    25 const TInt KMaxHeaderNameLength = 32;
       
    26 const TInt KMaxHeaderValueLength = 128;
       
    27 const TInt KMaxStatusTextLength = 32;
       
    28 const TInt KDPMaxContentTypeLength = 128;
       
    29 const TInt KMaxCharSetLength = 128;
       
    30 
       
    31 // This client accepts all content types.
       
    32 _LIT8( KAccept, "*/*" );
       
    33 // Used to specify the Accept Charset
       
    34 _LIT8( KAcceptCharset, "iso-8859-1, utf-8, iso-10646-ucs-2; q=0.6" );
       
    35 // Used to specify the Accept Language
       
    36 _LIT8( KAcceptLanguage, "en" );
       
    37 // Used to specify the Accept encoding
       
    38 _LIT8( KAcceptEncoding, "gzip" );
       
    39 // Some texts for header output
       
    40 _LIT( KDPColon, ": " );
       
    41 // Default Content-Type
       
    42 _LIT8( KDefaultContentType, "application/xml" );
       
    43 // Default CharSet
       
    44 _LIT8( KDefaultCharSet, "UTF-8" );
       
    45 
       
    46  // HTTP POST ContentType
       
    47 _LIT8( KPostContentType, "application/x-gzip" );
       
    48 /*!
       
    49  * Http Success 2xx Status codes
       
    50  */
       
    51 
       
    52 const TInt KOk = 200;
       
    53 const TInt KCreated = 201;
       
    54 const TInt KAccepted = 202;
       
    55 const TInt KNonAuthoritativeInformation = 203;
       
    56 const TInt KNoContent = 204;
       
    57 const TInt KResetContent = 205;
       
    58 const TInt KPartialContent = 206;
       
    59 /*!
       
    60  * Redirection 3xx status codes
       
    61  */
       
    62 const TInt KMultipleChoices = 300;
       
    63 const TInt KMovedPermanently = 301;
       
    64 const TInt KFound = 302;
       
    65 const TInt KSeeOther = 303;
       
    66 const TInt KNotModified = 304;
       
    67 const TInt KUseProxy = 305;
       
    68 /*
       
    69 This status code is not used as per RFC 2616
       
    70 const TInt KUnused = 306 
       
    71  */
       
    72 const TInt KTemporaryRedirect = 307;
       
    73 /*!
       
    74  * Client Error 4xx status codes
       
    75  */
       
    76 const TInt KBadRequest = 400;
       
    77 const TInt KUnauthorized = 401;
       
    78 const TInt KPaymentRequired = 402;
       
    79 const TInt KForbidden = 403;
       
    80 const TInt KNotFound = 404;
       
    81 const TInt KMethodNotAllowed = 405;
       
    82 const TInt KNotAcceptable = 406;
       
    83 const TInt KProxyAuthenticationRequired = 407;
       
    84 const TInt KRequestTimeout = 408;
       
    85 const TInt KConflict = 409;
       
    86 const TInt KGone = 410;
       
    87 const TInt KLengthRequired = 411;
       
    88 const TInt KPreconditionFailed = 412;
       
    89 const TInt KRequestEntityTooLarge = 413;
       
    90 const TInt KRequestURITooLong = 414;
       
    91 const TInt KUnsupportedMediaType = 415;
       
    92 const TInt KRequestedRangeNotSatisfiable = 416;
       
    93 const TInt KExpectationFailed = 417;
       
    94 /*!
       
    95  * Server Error 5xx status codes
       
    96  */
       
    97 const TInt KInternalServerError = 500;
       
    98 const TInt KNotImplemented = 501;
       
    99 const TInt KBadGateway = 502;
       
   100 const TInt KServiceUnavailable = 503;
       
   101 const TInt KGatewayTimeout = 504;
       
   102 const TInt KHTTPVersionNotSupported = 505;
       
   103 /*!
       
   104  * Timeout  code
       
   105  */
       
   106 const TInt KDataProviderTimeout =  - 12345;
       
   107 const TInt KDndTimedOut = -5120;
       
   108 
       
   109 #endif // IRDATAPROVIDERCONSTANTS_H
       
   110 
       
   111