diff -r e16d72588c28 -r 8a03a285ab14 omadrm/drmengine/server/inc/drmmeteringdb.h --- a/omadrm/drmengine/server/inc/drmmeteringdb.h Fri Mar 12 15:43:46 2010 +0200 +++ b/omadrm/drmengine/server/inc/drmmeteringdb.h Mon Mar 15 12:41:43 2010 +0200 @@ -22,7 +22,8 @@ // INCLUDES #include #include -#include +#include +#include #include "DRMPointerArray.h" // CONSTANTS @@ -37,103 +38,103 @@ // CLASS DECLARATION /** -* Content metering information database. This class manages storing -* information of Content ID, Rights Issuer ID, metered count and metered -* accumulated time. +* Content metering information database. This class manages storing +* information of Content ID, Rights Issuer ID, metered count and metered +* accumulated time. * * @lib RightsServer.exe * @since 3.2 */ NONSHARABLE_CLASS( RDrmMeteringDb ) { - + public: // Constructors and destructor - + /** * Constructor. * @since S60 3.2 */ RDrmMeteringDb( RFs& aFs ); - + /** * Default constructor. * @since S60 3.2 */ RDrmMeteringDb(); - + public: // New functions - + /** * Sets the iFs according to this reference. * * @since S60 3.2 - * @param aFs Reference to open file server session. + * @param aFs Reference to open file server session. */ void Set( RFs& aFs ); - + /** * Closes the database. * @since S60 3.2 */ void Close(); - + /** * Initializes the database. * @since S60 3.2 * @param aFileName File name of the database */ void InitL( const TDesC& aFileName ); - + /** * Destructor. * @since S60 3.2 */ ~RDrmMeteringDb(); - + /** * Add a metering data entry to the database. * @since S60 3.2 * @param aMeteringData One metering data entry */ void AddL( const CDrmMeteringDbData* aMeteringData ); - - /** - * Get the metering data list based on the Rights Issuer Id from the - * metering database. Return value is ETrue if at least one entry was - * found corresponding to the given Rights Issuer Id. Return value is - * EFalse if no entry was found. The function will leave if an error - * happens in the handling of the database or if the Rights Issuer Id + + /** + * Get the metering data list based on the Rights Issuer Id from the + * metering database. Return value is ETrue if at least one entry was + * found corresponding to the given Rights Issuer Id. Return value is + * EFalse if no entry was found. The function will leave if an error + * happens in the handling of the database or if the Rights Issuer Id * is empty or too long. * @since S60 3.2 * @param aRiId Rights Issuer Id * @param aMeteringDataList Metering data list for a Rights Issuer * @return Boolean */ - TBool GetL( const TDesC8& aRiId, + TBool GetL( const TDesC8& aRiId, CDRMPointerArray< CDrmMeteringDbData >& aMeteringDataList ); - + /** - * Delete all the metering data information associated to the given + * Delete all the metering data information associated to the given * Rights Issuer Id from the metering database. Return value is ETrue - * if at least one entry was found corresponding to the given Rights - * Issuer Id. Return value is EFalse if no entry was found. The function - * will leave if an error happens in the handling of the database or if - * the Rights Issuer Id is empty or too long. + * if at least one entry was found corresponding to the given Rights + * Issuer Id. Return value is EFalse if no entry was found. The function + * will leave if an error happens in the handling of the database or if + * the Rights Issuer Id is empty or too long. * @since S60 3.2 - * @param aRiId Rights Issuer Id + * @param aRiId Rights Issuer Id * @return Boolean */ TBool DeleteL( const TDesC8& aRiId ); - + private: // Private functions - + /** * Opens a database. * @since S60 3.2 * @param aDb Database. * @param aFileName File name. */ - void OpenDbL( RDbNamedDatabase& aDb, + void OpenDbL( RDbNamedDatabase& aDb, const TDesC& aFileName ); /** @@ -151,34 +152,34 @@ * @param aView View to initialize. */ void InitViewLC( RDbView& aView ); - + /** * Compare the Rights Issuer Id and Content Id to their counterparts in - * the current row of the view. Return value is ETrue only if both the + * the current row of the view. Return value is ETrue only if both the * Content Id and the Rights Issuer Id match their counterpart Ids in - * the view. Overloaded. - * + * the view. Overloaded. + * * @since S60 3.2 * @param aView View. * @param aCID Content Id * @param aRiId Rights Issuer Id * @return Boolean */ - TBool CompareIDL( RDbRowSet& aView, - const TDesC8& aCID, + TBool CompareIDL( RDbRowSet& aView, + const TDesC8& aCID, const TDesC8& aRiId ); - + /** - * Compare the Rights Issuer Id to its counterpart in the current row - * of the view. Overloaded. - * + * Compare the Rights Issuer Id to its counterpart in the current row + * of the view. Overloaded. + * * @since S60 3.2 * @param aView View. * @param aRiId Rights Issuer Id * @return Boolean */ TBool CompareIDL( RDbRowSet& aView, const TDesC8& aRiId ); - + /** * Push a cleanup item to the cleanup stack in order to rollback * the database. @@ -186,7 +187,7 @@ * @param aDb Database. */ void PushL( RDbDatabase& aDb ); - + /** * Pop the cleanup item pushed in by PushL * @since S60 3.2 @@ -196,10 +197,10 @@ private: // Data // File server session handle. Not owned by this object. RFs* iFs; - - // Metering database + + // Metering database RDbNamedDatabase iDb; - + }; -#endif //DRMMETERINGDB_H \ No newline at end of file +#endif //DRMMETERINGDB_H \ No newline at end of file