inc/impserrors.h
branchRCL_3
changeset 13 a941bc465d9f
parent 0 094583676ce7
equal deleted inserted replaced
12:6ca72c0fe49a 13:a941bc465d9f
       
     1 /*
       
     2 * Copyright (c) 2002-2004 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: Defines the base line for WV engine errors
       
    15 *              KImpsGeneralError  Imps_ERROR_BASE
       
    16 *
       
    17 *               The error codes retuned by WV engine are either: 
       
    18 *               a) General Symbian OS error code defined in e32std.h
       
    19 *               b) WV engine internal error code defined in impserror.h, range is
       
    20 *                  KImpsGeneralError ... (KImpsGeneralError - 99).
       
    21 *               c) CSP error code translated in form  
       
    22 *                  KImpsGeneralError - <CSP-error-code>
       
    23 *
       
    24 */
       
    25 
       
    26 
       
    27 #ifndef IMPSERRORS_H
       
    28 #define IMPSERRORS_H
       
    29 
       
    30 // the error range is -34000 -> -34999
       
    31 #define Imps_ERROR_BASE -34000
       
    32 
       
    33 
       
    34 // error codes must be defined as enum so that they can be
       
    35 // included by a source file that uses the error codes as ints
       
    36 
       
    37 // All errors are define relative to Imps_ERROR_BASE
       
    38 enum
       
    39     {
       
    40     // Unspecified error, used when no defined error matches.
       
    41     KImpsGeneralError = Imps_ERROR_BASE,
       
    42     // Terminal is already logged in SAP
       
    43     KImpsErrorAlreadyLogged = Imps_ERROR_BASE - 1,
       
    44     // Terminal has not yet logged in SAP
       
    45     KImpsErrorNotLogged = Imps_ERROR_BASE - 2,
       
    46     // Client not registered
       
    47     KImpsErrorNotRegistered = Imps_ERROR_BASE - 3,
       
    48     // Unauthorized request in SAP
       
    49     KImpsErrorUnauthorized = Imps_ERROR_BASE - 4,
       
    50     // General configuration error
       
    51     KImpsErrorConfig = Imps_ERROR_BASE - 5,
       
    52     // CSP Client Capabilities negotiation fails
       
    53     KImpsErrorCapabilities = Imps_ERROR_BASE - 6,
       
    54     // CSP Service negotiation fails
       
    55     KImpsErrorServices = Imps_ERROR_BASE - 7,
       
    56     // IAP connection closed or not found in CommDb
       
    57     KImpsErrorNoIAP = Imps_ERROR_BASE - 9,
       
    58 
       
    59     // message is too big to be sent - cannot allocate buffer
       
    60     KImpsErrorMessageTooBig = Imps_ERROR_BASE - 10,
       
    61     // message type invalid - cannot encode
       
    62     KImpsErrorUnknownMessageType = Imps_ERROR_BASE - 11,
       
    63 
       
    64     // This is not an actual error but a fake for online status changes
       
    65     KImpsNoIapStatus = Imps_ERROR_BASE - 12,
       
    66     KImpsOnlineStatus = Imps_ERROR_BASE - 13,
       
    67     KImpsOfflineStatus = Imps_ERROR_BASE - 14,
       
    68     KImpsNotLoggedStatus = Imps_ERROR_BASE - 15,
       
    69 
       
    70     // Logout not successful
       
    71     KImpsErrorOthersLogged = Imps_ERROR_BASE - 16,
       
    72 
       
    73     // Terminal off-line mode (flight mode)
       
    74     KImpsErrorTerminalOffLine = Imps_ERROR_BASE - 17,
       
    75     
       
    76     // Mapping of HTTP error codes. Rough categories only
       
    77     KImpsErrorHTTPConfiguration = Imps_ERROR_BASE - 18, // 1XX, 3XX
       
    78     KImpsErrorHTTPNotFound = Imps_ERROR_BASE - 19,      // 4XX
       
    79     KImpsErrorHTTPServerDown = Imps_ERROR_BASE - 20,    // 5XX
       
    80 
       
    81     // Errors from the transport adapter
       
    82     KImpsErrorSessionNotOpen = Imps_ERROR_BASE - 23,
       
    83     KImpsErrorBearerSuspended = Imps_ERROR_BASE - 24,
       
    84     KImpsErrorAlreadyClosed = Imps_ERROR_BASE - 25,
       
    85     KImpsErrorOffLine = Imps_ERROR_BASE - 26,
       
    86     KImpsErrorAllConnSlotsInUse = Imps_ERROR_BASE - 27,
       
    87 
       
    88     // Errors generated by illegal XML response
       
    89     KImpsErrorTID = Imps_ERROR_BASE - 40,
       
    90     KImpsErrorSID = Imps_ERROR_BASE - 41,
       
    91     KImpsErrorCID = Imps_ERROR_BASE - 42,
       
    92     KImpsErrorEncode = Imps_ERROR_BASE - 43,
       
    93     KImpsErrorDecode = Imps_ERROR_BASE - 44,
       
    94     KImpsErrorResponseStatus = Imps_ERROR_BASE - 45,
       
    95     KImpsErrorCSPVersion = Imps_ERROR_BASE - 46,
       
    96     KImpsErrorValidate = Imps_ERROR_BASE - 47,
       
    97 
       
    98     // Errors generated by illegal keys
       
    99     KImpsErrorKeyEmpty = Imps_ERROR_BASE - 50,
       
   100     KImpsErrorKeyIndexTooLarge = Imps_ERROR_BASE - 51,
       
   101     KImpsErrorKeyIndexInvalid = Imps_ERROR_BASE - 52,
       
   102 
       
   103     // New
       
   104     KImpsErrorShuttingDown = Imps_ERROR_BASE - 55,
       
   105     KImpsErrorAlreadyInUse = Imps_ERROR_BASE - 56
       
   106 
       
   107 
       
   108     };
       
   109 
       
   110 #endif      // ImpsERRORS_H   
       
   111