SenCredential.h

Go to the documentation of this file.
00001 /*
00002 * ==============================================================================
00003 *  Name        : SenCredential.h
00004 *  Part of     : Web Services Description
00005 *  Interface   : 
00006 *  Description : Class implements (web) service credential functionality
00007 *  Version     : 
00008 *
00009 *  Copyright © 2002-2005 Nokia. All rights reserved.
00010 *  This material, including documentation and any related 
00011 *  computer programs, is protected by copyright controlled by 
00012 *  Nokia. All rights are reserved. Copying, including 
00013 *  reproducing, storing, adapting or translating, any 
00014 *  or all of this material requires the prior written consent of 
00015 *  Nokia. This material also contains confidential 
00016 *  information which may not be disclosed to others without the 
00017 *  prior written consent of Nokia.
00018 * ==============================================================================
00019 */
00020 
00021 #ifndef SEN_CREDENTIAL_H
00022 #define SEN_CREDENTIAL_H
00023 
00024 //  INCLUDES
00025 #include <e32base.h>
00026 #include <s32strm.h>
00027 #include <SenBaseFragment.h>
00028 
00029 // CONSTANTS
00030 _LIT8(KCredentialsName,     "Credentials");
00031 _LIT8(KEndpointName,        "Endpoint");
00032 _LIT8(KSecurityMechIdName,  "SecurityMechID");
00033 _LIT8(KNotOnOrAfterName,    "NotOnOrAfter");
00034 _LIT8(KConditionsName,      "Conditions");
00035 
00036 // FORWARD DECLARATIONS
00037 class SenDateUtils;
00038 
00039 // CLASS DECLARATION
00040 
00046 class CSenCredential : public CSenBaseFragment
00047     {
00048     public:  // Constructors and destructor
00049         
00063         IMPORT_C static CSenCredential* NewL(const TDesC8& aNsUri,
00064                                              const TDesC8& aLocalName,
00065                                              const TDesC8& aQName,
00066                                              const RAttributeArray& aAttributes);
00067             
00082         IMPORT_C static CSenCredential* NewLC(const TDesC8& aNsUri,
00083                                               const TDesC8& aLocalName,
00084                                               const TDesC8& aQName,
00085                                               const RAttributeArray& aAttributes);
00086 
00101         IMPORT_C static CSenCredential* NewL(const TDesC8& aNsUri,
00102                                              const TDesC8& aLocalName,
00103                                              const TDesC8& aQName,
00104                                              const RAttributeArray& aAttributes,
00105                                              CSenElement& aParent);
00106 
00122         IMPORT_C static CSenCredential* NewLC(const TDesC8& aNsUri,
00123                                               const TDesC8& aLocalName,
00124                                               const TDesC8& aQName,
00125                                               const RAttributeArray& aAttributes,
00126                                               CSenElement& aParent);
00127 
00134         IMPORT_C static CSenCredential* NewL(const CSenCredential& aCredential);
00135 
00143         IMPORT_C static CSenCredential* NewLC(const CSenCredential& aCredential);
00144 
00148         IMPORT_C virtual ~CSenCredential();        
00149 
00150         // New functions
00151         
00157         IMPORT_C const TDesC8& Id();
00158 
00164         IMPORT_C TTime& ValidUntil();
00165 
00171         IMPORT_C void SetValidUntil(TTime& aTime);
00172 
00173     protected:  // Functions from base classes
00174 
00183         IMPORT_C virtual void StartElementL(const TDesC8& aNsUri,
00184                                             const TDesC8& aLocalName,
00185                                             const TDesC8& aQName,
00186                                             const RAttributeArray& aAttributes);
00187         
00188     private:
00189         
00193         IMPORT_C CSenCredential();
00194 
00203         IMPORT_C void ConstructL(const TDesC8& aNsUri,
00204                                  const TDesC8& aLocalName,
00205                                  const TDesC8& aQName,
00206                                  const RAttributeArray& aAttributes);
00207 
00218         IMPORT_C void ConstructL(const TDesC8& aNsUri,
00219                                  const TDesC8&  aLocalName,
00220                                  const TDesC8& aQName,
00221                                  const RAttributeArray& aAttributes,
00222                                  CSenElement& aParent);
00223 
00229         IMPORT_C void ConstructL(CSenCredential& aCredential);
00230 
00231         // New functions
00232 
00238         void SetIdL(const TDesC8& aId);
00239 
00240     private: // Data
00241         // Unique ID for this credential. Owned.
00242         HBufC8* iId;
00243         // One may use SenDateUtils to convert from XML date descrtor to TTime
00244         TTime iNotOnOrAfter;    
00245     };
00246 
00247 #endif // SEN_CREDENTIAL_H
00248 
00249 // End of File
00250 
00251 

Copyright © Nokia Corporation 2001-2007
Back to top