epoc32/include/agentdialog.h
branchSymbian2
changeset 2 2fe1408b6811
child 4 837f303aceeb
     1.1 --- /dev/null	Thu Jan 01 00:00:00 1970 +0000
     1.2 +++ b/epoc32/include/agentdialog.h	Tue Mar 16 16:12:26 2010 +0000
     1.3 @@ -0,0 +1,190 @@
     1.4 +/**
     1.5 +* Copyright (c) 1997-2009 Nokia Corporation and/or its subsidiary(-ies).
     1.6 +* All rights reserved.
     1.7 +* This component and the accompanying materials are made available
     1.8 +* under the terms of the License "Symbian Foundation License v1.0" to Symbian Foundation members and "Symbian Foundation End User License Agreement v1.0" to non-members
     1.9 +* which accompanies this distribution, and is available
    1.10 +* at the URL "http://www.symbianfoundation.org/legal/licencesv10.html".
    1.11 +*
    1.12 +* Initial Contributors:
    1.13 +* Nokia Corporation - initial contribution.
    1.14 +*
    1.15 +* Contributors:
    1.16 +*
    1.17 +* Description:
    1.18 +* Generic Connection Dialog Client
    1.19 +* 
    1.20 +*
    1.21 +*/
    1.22 +
    1.23 +
    1.24 +
    1.25 +
    1.26 +
    1.27 +/**
    1.28 + @file AGENTDIALOG.H
    1.29 + @internalTechnology
    1.30 +*/
    1.31 +
    1.32 +#ifndef __AGENTDIALOG_H__
    1.33 +#define __AGENTDIALOG_H__
    1.34 +
    1.35 +#include <e32std.h>
    1.36 +#include <cdbcols.h>
    1.37 +#include <cdblen.h>
    1.38 +//#include <comms-infras/commsdebugutility.h> Cannot be included because it conflicts with flogger
    1.39 +
    1.40 +
    1.41 +/**
    1.42 +Server name in EKA2 case
    1.43 +@internalTechnology
    1.44 +*/
    1.45 +_LIT(KCommsDialogServerName, "!NetDialDialogServer");
    1.46 +
    1.47 +//__FLOG_STMT(_LIT8(KDlgSvrLogSubsys, "agentdialog");)
    1.48 +//__FLOG_STMT(_LIT8(KDlgSvrLogComponent, "server");)
    1.49 +//__FLOG_STMT(_LIT8(KDlgCliLogComponent, "client");)
    1.50 +
    1.51 +class TConnectionPrefs
    1.52 +/**
    1.53 +Specifies the rank and desired direction of the connection and bearer.
    1.54 +
    1.55 +@internalTechnology
    1.56 +*/
    1.57 +	{
    1.58 +public:
    1.59 +	TUint32 iRank;
    1.60 +	TCommDbConnectionDirection iDirection;
    1.61 +	TUint32 iBearerSet;
    1.62 +	};
    1.63 +
    1.64 +class TIspConnectionNames
    1.65 +/**
    1.66 +Specifies the Connection Names for ISP.
    1.67 +
    1.68 +@internalTechnology
    1.69 +*/
    1.70 +	{
    1.71 +public:
    1.72 +	TBuf<KCommsDbSvrDefaultTextFieldLength> iServiceName;
    1.73 +	TBuf<KCommsDbSvrMaxColumnNameLength> iServiceTable;
    1.74 +	TBuf<KCommsDbSvrDefaultTextFieldLength> iModemName;
    1.75 +	TBuf<KCommsDbSvrDefaultTextFieldLength> iLocationName;
    1.76 +	TBuf<KCommsDbSvrDefaultTextFieldLength> iChargecardName;
    1.77 +	};
    1.78 +
    1.79 +class TAuthenticationPair
    1.80 +/**
    1.81 +Specifies the Authentication for the User Name and Password.
    1.82 +
    1.83 +@internalTechnology
    1.84 +*/
    1.85 +	{
    1.86 +public:
    1.87 +	TDes* iUsername;
    1.88 +	TDes* iPassword;
    1.89 +	};
    1.90 +
    1.91 +class TPctResponse
    1.92 +/**
    1.93 +Allows the user to see the login script running, see what is sent and received, and allows the user to type responses.
    1.94 +
    1.95 +@internalTechnology
    1.96 +*/
    1.97 +	{
    1.98 +public:
    1.99 +	TDes* iBuffer;
   1.100 +	};
   1.101 +
   1.102 +class TNewIapConnectionPrefs
   1.103 +/**
   1.104 +Specifies Connection Preference for the New IAP.
   1.105 +
   1.106 +@internalTechnology
   1.107 +*/
   1.108 +	{
   1.109 +public:
   1.110 +	TConnectionPrefs iPrefs;
   1.111 +	TInt iLastError;
   1.112 +	TBuf<KCommsDbSvrDefaultTextFieldLength> iName;
   1.113 +	};
   1.114 +
   1.115 +class RDialogNotifier : public RNotifier
   1.116 +/**
   1.117 +Client interface to allow engines or other low level components to communicate with the UI.
   1.118 +
   1.119 +Real implementations need three asynchronous message slots instead of RNotifiers default one slot
   1.120 +in order to implement the PCT functionality.  This is not used at all by the test dialog server
   1.121 +implementation.
   1.122 + 
   1.123 +@internalTechnology
   1.124 +*/
   1.125 +	{
   1.126 +public :
   1.127 +	TInt Connect();
   1.128 +	};
   1.129 +
   1.130 +class RGenConAgentDialogServer : public RSessionBase
   1.131 +/**
   1.132 +RGenConAgentDialogServer. This components needs to be written as a 
   1.133 +proper polymorphic DLL in JetStream.
   1.134 +
   1.135 +NOTE! Although the class inherits from RSessionBase this does not mean you 
   1.136 +have to implement the API as a client server mechanism.
   1.137 +
   1.138 +@internalTechnology
   1.139 +*/
   1.140 +	{
   1.141 +public:
   1.142 +	IMPORT_C RGenConAgentDialogServer();
   1.143 +	IMPORT_C ~RGenConAgentDialogServer();
   1.144 +	IMPORT_C TVersion Version() const;
   1.145 +	IMPORT_C TInt Connect();
   1.146 +	IMPORT_C void Close();
   1.147 +	IMPORT_C void ModemAndLocationSelection(TUint32& aModemId,TUint32& aLocationId,TRequestStatus& aStatus);
   1.148 +	IMPORT_C void IapConnection(TUint32& aIAP, const TConnectionPrefs& aPrefs, TRequestStatus& aStatus);
   1.149 +	IMPORT_C void IapConnection(TUint32& aIAP, const TConnectionPrefs& aPrefs, TInt aLastError, TRequestStatus& aStatus);
   1.150 +	IMPORT_C void WarnNewIapConnection(const TConnectionPrefs& aPrefs, TInt aLastError, const TDesC& aNewIapName, TBool& aResponse, TRequestStatus& aStatus);
   1.151 +	IMPORT_C void Login(TDes& aUsername, TDes& aPassword, TBool aIsReconnect, TRequestStatus& aStatus);
   1.152 +	IMPORT_C void Authenticate(TDes& aUsername, TDes& aPassword, TBool aIsReconnect, TRequestStatus& aStatus);
   1.153 +	IMPORT_C void Reconnect(TBool& aResponse, TRequestStatus& aStatus);
   1.154 +	IMPORT_C TInt OpenPct();
   1.155 +	IMPORT_C TInt WritePct(const TDesC& aData);
   1.156 +	IMPORT_C void ReadPct(TDes& aData, TRequestStatus& aStatus);
   1.157 +	IMPORT_C void DestroyPctNotification(TRequestStatus& aStatus);
   1.158 +	IMPORT_C void ClosePct();
   1.159 +	IMPORT_C void QoSWarning(TBool& aResponse, TRequestStatus& aStatus);
   1.160 +	IMPORT_C void CancelModemAndLocationSelection();
   1.161 +	IMPORT_C void CancelIapConnection();
   1.162 +	IMPORT_C void CancelWarnNewIapConnection();
   1.163 +	IMPORT_C void CancelLogin();
   1.164 +	IMPORT_C void CancelAuthenticate();
   1.165 +	IMPORT_C void CancelReconnect();
   1.166 +	IMPORT_C void CancelReadPct();
   1.167 +	IMPORT_C void CancelDestroyPctNotification();
   1.168 +	IMPORT_C void CancelQoSWarning();
   1.169 +	IMPORT_C void AccessPointConnection(TUint32& aAccessPoint, TInt aAccessPointGroup, TRequestStatus& aStatus);
   1.170 +	IMPORT_C void CancelAccessPointConnection();
   1.171 +	IMPORT_C void AccessPointConnection(TUint32& aAP, TUint32 aAPType, TUint32& aBearerAPInd, TUint32 aBearerAPType, TRequestStatus& aStatus);
   1.172 +
   1.173 +private:
   1.174 +	RDialogNotifier* iNotifier;
   1.175 +	TPckg<TUint32> iIAP;
   1.176 +	TPckg<TUint32> iModemId;
   1.177 +	TPckg<TUint32> iLocationId;
   1.178 +	TPckgBuf<TIspConnectionNames> iConNames;
   1.179 +	TPckgBuf<TConnectionPrefs> iPrefs;
   1.180 +	TPckg<TBool> iBool;
   1.181 +	TPckgBuf<TUint32> iPctBuffer;
   1.182 +	TPckgBuf<TPctResponse> iPctResponse;
   1.183 +	TPckgBuf<TAuthenticationPair> iAuthenticationPair;
   1.184 +	TPckgBuf<TNewIapConnectionPrefs> iNewIapPrefsBuffer;
   1.185 +	TPckgBuf<TUint32> iNotUsed;		// Parameters not used by plugin
   1.186 +	TRequestStatus iStatus;
   1.187 +	TPckg<TUint32> iAccessPoint;
   1.188 +//	__FLOG_DECLARATION_MEMBER;
   1.189 +	};
   1.190 +
   1.191 +IMPORT_C TInt StartDialogThread();
   1.192 +
   1.193 +#endif