ncdengine/inc/ncderrors.h
changeset 0 ba25891c3a9e
equal deleted inserted replaced
-1:000000000000 0:ba25891c3a9e
       
     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:   NCD Provider error code definitions.
       
    15 *
       
    16 */
       
    17 
       
    18 
       
    19 #ifndef NCD_ERRORS_H
       
    20 #define NCD_ERRORS_H
       
    21 
       
    22 const TInt KNcdErrorBase = -10000;
       
    23 
       
    24 /**
       
    25  * No content sources received from server.
       
    26  */
       
    27 const TInt KNcdErrorNoContentSources = -10001;
       
    28 
       
    29 /**
       
    30  * No valid purchase information
       
    31  */
       
    32 const TInt KNcdErrorNoPurchaseInformation = -10002;
       
    33 
       
    34 /**
       
    35  * Requested node removed from server.
       
    36  */
       
    37 const TInt KNcdErrorNodeWasRemoved = -10003;
       
    38 
       
    39 /**
       
    40  * Purchasing a subscription failed since the payment was already done.
       
    41  */
       
    42 const TInt KNcdErrorSubscriptionPaymentAlreadyDone = -10004;
       
    43 
       
    44 /**
       
    45  * Tried to buy an item which belongs to subscription which is not subscribed.
       
    46  */
       
    47 const TInt KNcdErrorSubscriptionNotSubscribed = -10005;
       
    48 
       
    49 /**
       
    50  * Tried to use subscription which is invalid.
       
    51  */
       
    52 const TInt KNcdErrorSubscriptionInvalid = -10006;
       
    53 
       
    54 /**
       
    55  * Tried to use subscription which has not enough credits or downloads.
       
    56  */
       
    57 const TInt KNcdErrorSubscriptionNotEnoughCredits = -10007;
       
    58 
       
    59 /**
       
    60  * General "not found" error.
       
    61  */
       
    62 const TInt KNcdErrorNotFound = -10008;
       
    63 
       
    64 /**
       
    65  * Purchase failed because no purchase information was received.
       
    66  */
       
    67 const TInt KNcdErrorNoPurchaseInformationReceived = -10009;
       
    68 
       
    69 
       
    70 /**
       
    71  * Errors used in purchase and subscription interfaces
       
    72  */
       
    73 
       
    74 /**
       
    75  * Tried to use purchase option or subscription that is obsolete.
       
    76  */
       
    77 const TInt KNcdErrorObsolete = -10010;
       
    78 
       
    79 /**
       
    80  * Subscription cannot be subscribed anymore.
       
    81  */
       
    82 const TInt KNcdErrorSubscriptionNotSubscribableAnymore = -10011;
       
    83 
       
    84 /**
       
    85  * Tried to use purchase option that is not a valid purchase option
       
    86  * of type SubscriptionPurchase.
       
    87  */
       
    88 const TInt KNcdErrorPurchaseOptionNotValidSubscriptionPurchase = -10012;
       
    89 
       
    90 /**
       
    91  * A mandatory query has been rejected and as a result an operation cannot
       
    92  * continue.
       
    93  */
       
    94 const TInt KNcdErrorMandatoryQueryRejected = -10013;
       
    95 
       
    96 /**
       
    97  * Some catalogs failed to load.
       
    98  */
       
    99 const TInt KNcdErrorSomeCatalogsFailedToLoad = -10014;
       
   100 
       
   101 /**
       
   102  * Master server URI has not been set
       
   103  */
       
   104 const TInt KNcdErrorNoMasterServerUri = KNcdErrorBase - 15;
       
   105 
       
   106 
       
   107 /**
       
   108  * Nothing to install, either everything has been installed or
       
   109  * no files have been downloaded that should be installed
       
   110  */
       
   111 const TInt KNcdErrorNothingToInstall = KNcdErrorBase - 16;
       
   112 
       
   113 /**
       
   114  * Creation of fixed AP fails.
       
   115  */
       
   116 const TInt KNcdErrorApCreationFailed = KNcdErrorBase - 17;
       
   117 
       
   118 /**
       
   119  * When doing manage subscription request to different servers,
       
   120  * some of the requests failed.
       
   121  */
       
   122 const TInt KNcdErrorSomeSubscriptionsFailedToUpdate = KNcdErrorBase - 18;
       
   123 
       
   124 /**
       
   125  * Tried to start an operation for a node that already had an on-going operation on
       
   126  * another client (with the same family uid).
       
   127  * Parallel operations on one node metadata are not supported. Previous
       
   128  * operation must complete before starting a new one.
       
   129  */
       
   130 const TInt KNcdErrorParallelOperationNotAllowed = KNcdErrorBase - 19;
       
   131 
       
   132 /**
       
   133  * Protocol error codes start here.
       
   134  * They are generated by subtracting the protocol error from
       
   135  * KNcdProtocolErrorBase.
       
   136  */
       
   137 const TInt KNcdProtocolErrorBase = -20000;
       
   138 
       
   139 
       
   140 /**
       
   141  * Status code for indicating that a theme was reinstalled.
       
   142  * It is possible that this code is returned even if the theme installation
       
   143  * failed when reinstalling a theme.
       
   144  */
       
   145 const TInt KNcdThemeReinstalled = 50000;
       
   146 
       
   147 /**
       
   148  * Status code for indicating that a theme was possibly reinstalled.
       
   149  * It is possible that this code is returned even if the theme installation
       
   150  * failed.
       
   151  */
       
   152 const TInt KNcdThemePossiblyReinstalled = 50001;
       
   153 
       
   154 
       
   155 /**
       
   156  * Provider creation will succeed with status code 1 if all of client's
       
   157  * databases were deleted because the client had crashed the provider too 
       
   158  * many times
       
   159  */
       
   160 const TInt KNcdDatabasesClearedAfterCrash = 1;
       
   161 
       
   162 /**
       
   163  * Provider creation will succeed with status code 2 if the purchase
       
   164  * history was deleted because it was of wrong version
       
   165  * 
       
   166  * This will be combined with KNcdGeneralDatabaseVersionMismatch if
       
   167  * both purchase history and all other databases are of wrong version or
       
   168  * if the version information can not be read at all
       
   169  */
       
   170 const TInt KNcdPurchaseHistoryVersionMismatch = 2;
       
   171 
       
   172 /**
       
   173  * Provider creation will succeed with status code 4 if general databases
       
   174  * (everything else but purchase history) were deleted because they were
       
   175  * of wrong version
       
   176  * 
       
   177  * @see KNcdPurchaseHistoryVersionMismatch
       
   178  */
       
   179 const TInt KNcdGeneralDatabaseVersionMismatch = 4;
       
   180 
       
   181 #endif // NCD_ERRORS_H