sl@0: /* sl@0: * Copyright (c) 2007-2009 Nokia Corporation and/or its subsidiary(-ies). sl@0: * All rights reserved. sl@0: * This component and the accompanying materials are made available sl@0: * under the terms of the License "Eclipse Public License v1.0" sl@0: * which accompanies this distribution, and is available sl@0: * at the URL "http://www.eclipse.org/legal/epl-v10.html". sl@0: * sl@0: * Initial Contributors: sl@0: * Nokia Corporation - initial contribution. sl@0: * sl@0: * Contributors: sl@0: * sl@0: * Description: sl@0: * sl@0: */ sl@0: sl@0: sl@0: /** sl@0: @file sl@0: @publishedPartner sl@0: @released sl@0: */ sl@0: sl@0: #ifndef FINGERPRINT_H sl@0: #define FINGERPRINT_H sl@0: sl@0: #include sl@0: #include sl@0: sl@0: namespace UserPromptService sl@0: { sl@0: /** sl@0: Class that represents the fingerprint data for a stored decision. sl@0: sl@0: The raw fingerprint data must be between one and KMaxFingerprintLength bytes in sl@0: length and are typically created from selected parts of the destination and opaque fields. sl@0: \n sl@0: E.g. Hash("GPRS") or Hash("+442071541000") or "ALL"\n sl@0: sl@0: Since hash functions are irreversible the fingerprint may also include a human readable sl@0: string of up to KMaxDescriptionLength characters in length that describes the data used to sl@0: generate the hash. This may be used by a management user interface that allows a device user sl@0: to rescind individual decisions. sl@0: sl@0: This field is stored in the decision record but is otherwise unused by the User Prompt Service. sl@0: */ sl@0: NONSHARABLE_CLASS(CFingerprint) : public CBase sl@0: { sl@0: public: sl@0: IMPORT_C static CFingerprint* NewL(const TDesC8& aFingerprint, const TDesC& aDescription); sl@0: IMPORT_C static CFingerprint* NewLC(const TDesC8& aFingerprint, const TDesC& aDescription); sl@0: sl@0: IMPORT_C const TDesC8& Fingerprint() const; sl@0: IMPORT_C const TDesC& Description() const; sl@0: ~CFingerprint(); sl@0: sl@0: private: sl@0: CFingerprint(); sl@0: void ConstructL(const TDesC8& aFingerprint, const TDesC& aDescription); sl@0: sl@0: HBufC8* iFingerprint; ///< The raw fingerprint data sl@0: HBufC* iDescription; ///< Describes the data used to generate the hash sl@0: }; sl@0: } sl@0: sl@0: #endif // FINGERPRINT_H