examples/Networking/SecureSockets/SecureSockets.h

00001 // Copyright (c) 2001-2009 Nokia Corporation and/or its subsidiary(-ies).
00002 // All rights reserved.
00003 // This component and the accompanying materials are made available
00004 // under the terms of "Eclipse Public License v1.0"
00005 // which accompanies this distribution, and is available
00006 // at the URL "http://www.eclipse.org/legal/epl-v10.html".
00007 //
00008 // Initial Contributors:
00009 // Nokia Corporation - initial contribution.
00010 //
00011 // Contributors:
00012 //
00013 // Description:
00014 //
00015 
00016 #include <basched.h>
00017 #include <eikenv.h>
00018 #include <coecntrl.h>
00019 #include <eikappui.h>
00020 #include <e32keys.h>
00021 #include <eikconso.h>
00022 #include <eikapp.h>
00023 #include <eikdoc.h>
00024 #include <eikon.rsg>
00025 #include <eikinfo.h>
00026 #include <eikon.hrh>
00027 
00028 #include <securesockets.rsg>
00029 #include "SecEngine.h"
00030 
00031 #ifndef _SECAPP_H_
00032 #define _SECAPP_H_
00033 
00034 
00036 const TUid KUidSecApp = {0xE8000068};
00037 
00041 class CConsoleControl : public CCoeControl
00042         {
00043 public:
00044         static CConsoleControl* NewL(const TRect& aClientRect);
00045         ~CConsoleControl();
00046         void ConstructL(const TRect& aClientRect);
00047         CConsoleBase& Console();
00048 
00049         // Override CCoeControl
00050     void ActivateL();
00051 
00052 protected:
00053         CConsoleControl() {}
00054 
00055 private:
00056         CEikConsoleScreen* iConsole;    // Standard console control
00057         };
00058 
00062 class CSettingsDialog: public CEikDialog
00063         {
00064 public:
00070         static TBool RunDlgLD(TConnectSettings& aConnectSettings);
00071 
00072 private:
00077         CSettingsDialog(TConnectSettings& aConnectSettings);
00078 
00079         // From CEikDialog
00081         void PreLayoutDynInitL();
00083         TBool OkToExitL(TInt aButtonId);
00084 
00085 private:
00087         TConnectSettings& iConnectSettings;
00088         };
00089 
00093 class CSecAppUi : public CEikAppUi
00094     {
00095 public:
00096         CSecAppUi(CSecEngine* aSecEngine);
00097     void ConstructL();
00098         ~CSecAppUi();
00099 
00100 private:
00101         // Override CEikAppUi
00102     void HandleCommandL(TInt aCommand);
00103         void DynInitMenuPaneL(TInt aResourceId, CEikMenuPane* aMenuPane);
00104 
00105 private:
00106         CConsoleControl* iConsoleControl;
00107         CSecEngine* iSecEngine;
00108         TConnectSettings iConnectSettings;
00109 
00110         RFile iOutputFile;
00111         TFileName iOutputFileName;
00112         };
00113 
00117 class CSecDocument : public CEikDocument
00118         {
00119 public:
00120         CSecDocument(CEikApplication& aApp);
00121         static CSecDocument* NewL(CEikApplication& aApp);
00122         ~CSecDocument();
00123         void ConstructL();
00124 private:
00125         // Override CApaDocument
00126         CEikAppUi* CreateAppUiL();
00127 private:
00128         CSecEngine* iSecEngine; // Document owns the engine
00129         };
00130 
00134 class CSecApplication : public CEikApplication
00135         {
00136 private: // from CApaApplication
00137         CApaDocument* CreateDocumentL();
00138         TUid AppDllUid() const;
00139         };
00140 #endif
00141 
00142 
00143 

Generated on Thu Jan 21 10:33:00 2010 for TB10.1 Example Applications by  doxygen 1.5.3