Original Symbian headers
Selected EUSER, Window Server, networking, graphics and device declarations
Loading...
Searching...
No Matches
es_sock.h
Go to the documentation of this file.
1// Copyright (c) 1997-2009 Nokia Corporation and/or its subsidiary(-ies).
2// All rights reserved.
3// This component and the accompanying materials are made available
4// under the terms of "Eclipse Public License v1.0"
5// which accompanies this distribution, and is available
6// at the URL "http://www.eclipse.org/legal/epl-v10.html".
7//
8// Initial Contributors:
9// Nokia Corporation - initial contribution.
10//
11// Contributors:
12//
13// Description:
14//
15
22#if !defined(__ES_SOCK_H__)
23#define __ES_SOCK_H__
24
25
26#include <e32base.h>
27#include <nifvar.h>
28
29#undef _DEBUG_SOCKET_FUNCTIONS
30#if defined(_DEBUG)
31#define _DEBUG_SOCKET_FUNCTIONS
32#endif
33
34#include <comms-infras/metacontainer.h>
35#include <elements/sd_errors.h>
36#include <comms-infras/es_parameterset.h>
37
38#include <comms-infras/es_event.h>
39
40using Meta::STypeId;
41using Meta::SMetaDataECom;
42using Meta::RMetaDataEComContainer;
43
44
45// Forward declaration of CCommsDataObjectBase
46namespace ESock
47{
48 class CCommsDataObjectBase;
49}
50
54_LIT8(SOCKET_SERVER_MAIN_MODULE_NAME, "ESock_Main"); // Worker 0
55_LIT8(SOCKET_SERVER_IP_MODULE_NAME, "ESock_IP"); // Worker 1
56_LIT8(SOCKET_SERVER_BT_MODULE_NAME, "ESock_Bt"); // Worker 2
57_LIT8(SOCKET_SERVER_IR_MODULE_NAME, "ESock_Ir"); // Worker 3
58_LIT8(SOCKET_SERVER_SMSWAP_MODULE_NAME, "ESock_SmsWap"); // Worker 4
69const TUint KConnectionUp = 7000;
79const TUint KConnectionDown = 8000;
80
81
82
88const TUint KESockDefaultMessageSlots=8;
89
90
99const TUint KMaxSubConnectionEventSize = 512;
100
109typedef TUint TSubConnectionUniqueId;
110
119typedef TBuf8<KMaxSubConnectionEventSize> TSubConnectionNotificationBuf;
120//
121const TUint KUseEmbeddedUniqueId = 0; //< Used by RConnection to identify cases where the subconnection id is embedded in the data structure
122
123const TUint KConnProgressDefault = 0; //< Default Connection Progress
124
125class TSessionPref
133 {
134public:
135 IMPORT_C TSessionPref();
136public:
138 TUint iAddrFamily;
140 TUint iProtocol;
142 TUint iReserved;
144 TUint iReserved1;
146 TUint iReserved2;
148 TUint iReserved3;
151 };
153class TNifProgress
161public:
162 inline TNifProgress();
163 inline TNifProgress(TInt aStage, TInt aError);
164 inline TBool operator==(const TNifProgress& aRHS) const;
165 TInt iStage;
166 TInt iError;
167 };
168
169class TNifAgentInfo
177public:
180
199struct SSockAddr
204 {
206 TUint iFamily;
208 TUint iPort;
209 };
210
216const TUint KMaxSockAddrSize=0x20;
217
218class TSockAddr : public TBuf8<KMaxSockAddrSize>
237 {
238public:
239 IMPORT_C TSockAddr();
240 IMPORT_C TSockAddr(TUint aFamily);
241 IMPORT_C TUint Family() const;
242 IMPORT_C void SetFamily(TUint aFamily);
243 IMPORT_C TUint Port() const;
244 IMPORT_C void SetPort(TUint aPort);
245 IMPORT_C TBool CmpPort(const TSockAddr& anAddr) const;
246 IMPORT_C TInt GetUserLen();
247protected:
248 IMPORT_C void SetUserLen(TInt aLen);
249 inline TUint8* UserPtr() const;
250private:
251 inline SSockAddr* BasePtr() const;
252 };
253
254// Address families (based upon protocol IDs used by ARP/REVARP)
258const TUint KAFUnspec=0;
259
260// Socket types
264const TUint KSockStream=1;
266const TUint KSockDatagram=2;
268const TUint KSockSeqPacket=3;
270const TUint KSockRaw=4;
271
272// constants for various socket calls - can't be enums cos they're largely defined by protocols
273// The following constants are used to define level parameters for RSocket::Ioctl(), RSocket::GetOpt()
274// and RSocket::SetOpt().
278const TInt KSOLSocket=1;
280const TInt KLevelUnspecified=0;
281
282// Socket options defined by the server.
283// Used through RSocket::SetOpt(), and RSocket::GetOpt() with anOptionLevel set
284// to KSOLSocket. Options can be both get and set unless otherwise.
285// stated.
286// Notes:
287// Setting the send and receive buffer sizes explicitly can help to reduce
288// the memory requirements if many data sockets are used in an application. If a
289// socket is datagram-oriented and its receive/send buffer size is set
290// to KSocketBufSizeUndefined, then the initial buffer size will
291// be KSocketDefaultBufferSize and buffers will grow to accommodate
292// larger sends/receives. If the buffer size is set explicitly for
293// datagram-oriented sockets, sends which exceed the set size will fail
294// with KErrTooBig and receives will be truncated. For stream based
295// sockets there should be no noticeable effect on client reads, unless the buffer
296// size is set to a prohibitively low value.
304const TUint KSODebug=1;
310const TUint KSORecvBuf=2;
316const TUint KSOSendBuf=3;
323const TUint KSONonBlockingIO=4;
329const TUint KSOBlockingIO=5;
333const TUint KSOSelectPoll=6;
336const TUint KSOReadBytesPending=7;
340const TUint KSOUrgentDataOffset=8;
346const TUint KSOSelectLastError=9;
347
348
355const TUint KSOEnableTransfer = 10;
361const TUint KSODisableTransfer = 11;
363// The following constants relating to buffer sizes are defined
364
368const TInt KSocketDefaultBufferSize=4096;
370//internal
371const TUint KSocketInternalOptionBit=0x80000000; //< Must not be set for client requests
372
383const TUint KIOctlSelect=1;
384
385// Select ioctl states
386// Socket status. See also KSOSelectLastError and KSOSelectPoll.
390const TUint KSockSelectRead =0x00000001;
392const TUint KSockSelectWrite =0x00000002;
394const TUint KSockSelectExcept =0x00000004;
396const TUint KSockSelectReadContinuation = 0x01000000;
397
398// Socket write flags
404const TUint KSockWriteUrgent=0x00000001;
406const TUint KSocketInternalWriteBit=0x80000000;
408const TUint KSockWriteSystemMask=0xFF000000;
409
410// Socket read flags
417const TUint KSockReadPeek=0x00000001;
419const TUint KSocketInternalReadBit=0x80000000;
421const TUint KSockReadContinuation = 0x01000000;
422// Types
423
427enum TByteOrder
428 {
435 };
437//
438// Protocol Service information bitmasks.
439// The following constants are defined for
440// TServerProtocolDesc and TProtocolDesc
441//
445const TUint KSIConnectionLess=0x00000001;
447const TUint KSIReliable=0x00000002;
449const TUint KSIInOrder=0x00000004;
451const TUint KSIMessageBased=0x00000008;
455const TUint KSIStreamBased=0x00000010;
457const TUint KSIPseudoStream=0x00000020;
459const TUint KSIUrgentData=0x00000040;
461const TUint KSIConnectData=0x00000080;
463const TUint KSIDisconnectData=0x00000100;
465const TUint KSIBroadcast=0x00000200;
467const TUint KSIMultiPoint=0x00000400;
469const TUint KSIQOS=0x00000800;
471const TUint KSIWriteOnly=0x00001000;
473const TUint KSIReadOnly=0x00002000;
475const TUint KSIGracefulClose=0x00004000;
477const TUint KSICanReconnect=0x00008000;
480const TUint KSIPeekData=0x00010000;
485const TUint KSIRequiresOwnerInfo=0x00020000; // SetOption(KSoOwnerInfo) invoked on each SAP
487const TUint KSIReserved=0xFFFC0000;
488
489//
490// Naming service constants
491// The following constants are defined for
492// TServerProtocolDesc and TProtocolDesc
493//
498const TUint KNSNameResolution=0x00000001;
500const TUint KNSHierarchicalNaming=0x00000002;
505const TUint KNSRemoteDiscovery=0x00000004;
508const TUint KNSServiceResolution=0x00000008;
510const TUint KNSNameRegistration=0x00000010;
512const TUint KNSServiceRegistration=0x00000020;
515const TUint KNSDynamicAddressing=0x00000040;
517const TUint KNSInfoDatabase=0x00000080;
522const TUint KNSRequiresConnectionStartup=0x00000100;
524const TUint KNSReserved=0xFFFFFE00;
525
526// Security Schemes
527// The following constants are defined for
528// TServerProtocolDesc and TProtocolDesc
532const TUint KSocketNoSecurity=0x00000000;
536const TUint KSecureSockets=0x00000001;
537
538// Special message sizes
539// The following constants are defined for
540// TServerProtocolDesc and TProtocolDesc
546const TInt KSocketMessageSizeUndefined=1;
550const TInt KSocketMessageSizeNoLimit=-1;
551
552
556const TUint KUndefinedSockType=0xFFFFFFFF;
557
562const TUint KUndefinedProtocol=0xFFFFFFFE;
563
569
578
585struct TProtocolDesc
587 {
588public:
595 TUint iAddrFamily;
597 TUint iSockType;
611 TUint iServiceInfo;
624 TInt iMessageSize;
625 };
626
627// socket errors
633const TInt KErrWouldBlock=-1000;
634
644const TInt KErrConnectionTerminated=-17210;
645
646const TInt KErrCannotFindProtocol = Den::KErrPlayerNotFound;
647const TInt KErrTierNotFound = -17212;
648const TInt KErrConnectionContention = -17213;
649
658const TInt KErrProtocolNotReady = -17214;
659
660// -17215 used for non published error. Do not use here.
661
662
668
669
670namespace ESockDebug
671 {
672 class TControlMsg;
673 }
675class RSocket;
676class RConnection;
678NONSHARABLE_CLASS(RCommsSession) : public RSessionBase
680 friend class RCommsApiExtensionBase;
681 friend class CCommsSessionApiExtProvider;
682 };
683
684class RSocketServ : public RCommsSession
707 {
708public:
709 IMPORT_C RSocketServ();
710 IMPORT_C TInt Connect(TUint aMessageSlots = (TUint) -1);
711 IMPORT_C TInt Connect(const TSessionPref& aPref, TUint aMessageSlots = (TUint) -1);
712 IMPORT_C TVersion Version() const;
713 IMPORT_C TInt NumProtocols(TUint& aCount);
714 IMPORT_C TInt GetProtocolInfo(TUint anIndex,TProtocolDesc& aProtocol);
715 IMPORT_C TInt FindProtocol(const TProtocolName& aName,TProtocolDesc& aProtocol);
716 IMPORT_C void StartProtocol(TUint anAddrFamily,TUint aSockType,TUint aProtocol,TRequestStatus& aStatus);
717 IMPORT_C void StopProtocol(TUint anAddrFamily,TUint aSockType,TUint aProtocol,TRequestStatus& aStatus);
718 IMPORT_C TInt InstallExtension(const TDesC& aDllName, const TDesC& aArgs=TPtrC());
719 IMPORT_C void SetExclusiveMode(TRequestStatus& aStatus);
720 IMPORT_C void ClearExclusiveMode();
721 IMPORT_C TInt __DbgMarkHeap();
722 IMPORT_C TInt __DbgCheckHeap(TInt aCount);
723 IMPORT_C TInt __DbgMarkEnd(TInt aCount);
724 IMPORT_C TInt __DbgFailNext(TInt aCount);
725 IMPORT_C TBool __DbgCheckFailNext() const;
726 IMPORT_C TInt __DbgFailNextMbuf(TInt aCount);
727 IMPORT_C TInt __DbgSetMbufPoolLimit(TInt asize);
728 IMPORT_C TInt __DbgCheckMbuf(TInt asize);
729 IMPORT_C TInt __DbgMbufFreeSpace();
730 IMPORT_C TInt __DbgMbufTotalSpace();
731 IMPORT_C TInt __DbgControl(const ESockDebug::TControlMsg& aRequestMsg);
732 };
734NONSHARABLE_CLASS(RCommsSubSession) : public RSubSessionBase
735 {
736 friend class RCommsApiExtensionBase;
737 friend class CCommsSubSessionApiExtProvider;
738 };
739
740class RSubConnection;
741class RSocket : public RCommsSubSession
761friend class RSocketServ;
762public:
765 enum TShutdown
766 {
768 ENormal,
775 };
776public:
777 IMPORT_C RSocket();
778
779 IMPORT_C TInt Open(RSocketServ& aServer,TUint addrFamily,TUint sockType,TUint protocol);
780 IMPORT_C TInt Open(RSocketServ& aServer,TUint addrFamily,TUint sockType,TUint protocol, RConnection& aConnection);
781 IMPORT_C TInt Open(RSocketServ& aServer,TUint addrFamily,TUint sockType,TUint protocol, RSubConnection& aSubConnection);
782 IMPORT_C TInt Open(RSocketServ &aServer,const TDesC& aName);
783 IMPORT_C TInt Open(RSocketServ& aServer);
784 IMPORT_C void Send(const TDesC8& aDesc,TUint someFlags,TRequestStatus& aStatus);
785
786 IMPORT_C void Send(const TDesC8& aDesc,TUint someFlags,TRequestStatus& aStatus,TSockXfrLength& aLen);
787 IMPORT_C void CancelSend();
788
789 IMPORT_C void Recv(TDes8& aDesc,TUint flags,TRequestStatus& aStatus);
790
791 IMPORT_C void Recv(TDes8& aDesc,TUint flags,TRequestStatus& aStatus,TSockXfrLength& aLen);
792
793 IMPORT_C void RecvOneOrMore(TDes8& aDesc,TUint flags,TRequestStatus& aStatus,TSockXfrLength& aLen);
794 IMPORT_C void RecvOneOrMore(TDes8& aDesc,TUint flags,TRequestStatus& aStatus);
795 IMPORT_C void CancelRecv();
796
797 IMPORT_C void Read(TDes8& aDesc,TRequestStatus& aStatus);
798 IMPORT_C void CancelRead();
799
800 IMPORT_C void Write(const TDesC8& aDesc,TRequestStatus& aStatus);
801 IMPORT_C void CancelWrite();
802 IMPORT_C void SendTo(const TDesC8& aDesc,TSockAddr& anAddr,TUint flags,TRequestStatus& aStatus);
804 IMPORT_C void SendTo(const TDesC8& aDesc,TSockAddr& anAddr,TUint flags,TRequestStatus& aStatus,TSockXfrLength& aLen);
806 IMPORT_C void RecvFrom(TDes8& aDesc,TSockAddr& anAddr,TUint flags,TRequestStatus& aStatus);
808 IMPORT_C void RecvFrom(TDes8& aDesc,TSockAddr& anAddr,TUint flags,TRequestStatus& aStatus,TSockXfrLength& aLen);
809 IMPORT_C void Connect(TSockAddr& anAddr,TRequestStatus& aStatus);
810 IMPORT_C void Connect(TSockAddr& anAddr,const TDesC8& aConnectDataOut,TDes8& aConnectDataIn,TRequestStatus& aStatus);
811 IMPORT_C void CancelConnect();
812 IMPORT_C TInt Bind(TSockAddr& anAddr);
813 IMPORT_C TInt SetLocalPort(TInt aPort);
814 IMPORT_C void Accept(RSocket& aBlankSocket,TRequestStatus& aStatus);
815 IMPORT_C void Accept(RSocket& aBlankSocket,TDes8& aConnectData,TRequestStatus& aStatus);
816 IMPORT_C void CancelAccept();
817 IMPORT_C TInt Listen(TUint qSize);
818 IMPORT_C TInt Listen(TUint qSize,const TDesC8& aConnectData);
819 IMPORT_C TInt SetOpt(TUint anOptionName,TUint anOptionLevel,const TDesC8& anOption=TPtrC8(NULL,0));
820 IMPORT_C TInt SetOpt(TUint anOptionName,TUint anOptionLevel,TInt anOption);
821 IMPORT_C TInt GetOpt(TUint anOptionName,TUint anOptionLevel,TDes8& anOption);
822 IMPORT_C TInt GetOpt(TUint anOptionName,TUint anOptionLevel,TInt& anOption);
823 IMPORT_C void Ioctl(TUint aCommand,TRequestStatus& aStatus,TDes8* aDesc=NULL,TUint aLevel=KLevelUnspecified);
824 IMPORT_C void CancelIoctl();
825 IMPORT_C TInt GetDisconnectData(TDes8& aDesc);
826 IMPORT_C void LocalName(TSockAddr& anAddr);
827 IMPORT_C TUint LocalPort();
828 IMPORT_C void RemoteName(TSockAddr& anAddr);
829 IMPORT_C void Close();
830 IMPORT_C void Shutdown(TShutdown aHow,TRequestStatus& aStatus);
831 IMPORT_C void Shutdown(TShutdown aHow,const TDesC8& aDisconnectDataOut,TDes8& aDisconnectDataIn,TRequestStatus& aStatus);
832 IMPORT_C void CancelAll();
833 IMPORT_C TInt Info(TProtocolDesc& aProtocol);
834 IMPORT_C TInt Name(TName& aName);
835 IMPORT_C TInt Transfer(RSocketServ& aServer, const TDesC& aName);
836 };
837
838class TNameRecord
842 {
843public:
844 inline TNameRecord();
845
846 enum
847 {
848 EAlias=0x00000001,
849 EPartial=0x00000002,
851 };
861 TInt iFlags;
862 };
869
898public:
899 IMPORT_C TInt Open(RSocketServ& aSocketServer,TUint anAddrFamily,TUint aProtocol);
900 IMPORT_C TInt Open(RSocketServ& aSocketServer,TUint anAddrFamily,TUint aProtocol, RConnection& aConnection);
901 IMPORT_C void GetByName(const TDesC& aName,TNameEntry& aResult,TRequestStatus& aStatus);
902 IMPORT_C TInt GetByName(const TDesC& aName,TNameEntry& aResult);
903 IMPORT_C void Next(TNameEntry& aResult,TRequestStatus& aStatus);
904 IMPORT_C TInt Next(TNameEntry& aResult);
905 IMPORT_C void GetByAddress(const TSockAddr& anAddr,TNameEntry& aResult,TRequestStatus& aStatus);
906 IMPORT_C TInt GetByAddress(const TSockAddr& anAddr,TNameEntry& aResult);
907 IMPORT_C TInt GetHostName(TDes& aName);
908 IMPORT_C void GetHostName(TDes& aName,TRequestStatus& aStatus);
909 IMPORT_C TInt SetHostName(const TDesC& aName);
910 IMPORT_C void Close();
911 IMPORT_C void Cancel();
913 IMPORT_C void Query(const TDesC8& aQuery, TDes8& aResult, TRequestStatus& aStatus);
914 IMPORT_C TInt Query(const TDesC8& aQuery, TDes8& aResult);
915 IMPORT_C void QueryGetNext(TDes8& aResult, TRequestStatus& aStatus);
916 IMPORT_C TInt QueryGetNext(TDes8& aResult);
917 IMPORT_C TInt SetOpt(TUint anOptionName,TUint anOptionLevel,const TDesC8& anOption=TPtrC8(NULL,0));
919private:
920 };
934 {
935public:
936 IMPORT_C TInt Open(RSocketServ& aSocketServer,TUint anAddrFamily,TUint sockType,TUint aProtocol);
937 IMPORT_C void GetByName(const TDesC& aName,TPortNum& aPort,TRequestStatus& aStatus);
938 IMPORT_C TInt GetByName(const TDesC& aName,TPortNum& aPort);
939 IMPORT_C void GetByNumber(const TUint aPort,TDes& aName,TRequestStatus& aStatus);
940 IMPORT_C TInt GetByNumber(const TUint aPort,TDes& aName);
941 IMPORT_C void RegisterService(const TDesC& aName,const TUint& aPort,TRequestStatus& aStatus);
942 IMPORT_C TInt RegisterService(const TDesC& aName,const TUint& aPort);
943 IMPORT_C void RemoveService(const TDesC& aName,const TUint& aPort,TRequestStatus& aStatus);
944 IMPORT_C TInt RemoveService(const TDesC& aName,const TUint& aPort);
945 IMPORT_C void Close();
946 IMPORT_C void Cancel();
947private:
948 };
949
950class RNetDatabase: public RSubSessionBase
966 {
967public:
968 IMPORT_C TInt Open(RSocketServ& aSocketServer,TUint anAddrFamily,TUint aProtocol);
969 IMPORT_C void Query(const TDesC8& aQuery,TDes8& aResult,TRequestStatus& aStat);
970 IMPORT_C TInt Query(const TDesC8& aQuery,TDes8& aResult);
971 IMPORT_C void Add(const TDesC8& anItem,TRequestStatus& aStat);
972 IMPORT_C TInt Add(const TDesC8& anItem);
973 IMPORT_C void Remove(const TDesC8& anItem,TRequestStatus& aStat);
974 IMPORT_C TInt Remove(const TDesC8& anItem);
975 IMPORT_C void Close();
976 IMPORT_C void Cancel();
977private:
978 };
979
980
986const TUint KConnectionTypeDefault = 0x0800; // KAfInet is the default connection type
987
988
989class TConnPref;
990class TSubConnectionInfo;
991class TSubConnectionEvent;
992
993class RConnection : public RCommsSubSession
1049public:
1060 };
1062 enum TConnStopType
1063 {
1068
1074 };
1075
1079 IMPORT_C RConnection();
1080 IMPORT_C virtual ~RConnection();
1081 IMPORT_C TInt Open(RSocketServ& aSocketServer, TUint aConnectionType = KConnectionTypeDefault);
1082 IMPORT_C TInt Open(RSocketServ& aSocketServer, TName& aName);
1083 IMPORT_C void Close();
1085 IMPORT_C void Start(TRequestStatus& aStatus);
1086 IMPORT_C void Start(TConnPref& aPref, TRequestStatus& aStatus);
1087 IMPORT_C TInt Start();
1088 IMPORT_C TInt Start(TConnPref& aPref);
1089 IMPORT_C TInt Stop();
1090 IMPORT_C TInt Stop(TConnStopType aStopType);
1091 IMPORT_C TInt Stop(TSubConnectionUniqueId aSubConnectionUniqueId);
1092 IMPORT_C TInt Stop(TSubConnectionUniqueId aSubConnectionUniqueId, TConnStopType aStopType);
1093
1094 IMPORT_C void WaitForIncoming(RSubConnection& aIncomingSubConnection, TRequestStatus& aStatus);
1095 IMPORT_C TInt WaitForIncoming(RSubConnection& aIncomingSubConnection);
1096 IMPORT_C void CancelWaitForIncoming();
1097
1098 IMPORT_C void ProgressNotification(TNifProgressBuf& aProgress, TRequestStatus& aStatus, TUint aSelectedProgress = KConnProgressDefault);
1099 IMPORT_C void ProgressNotification(TSubConnectionUniqueId aSubConnectionUniqueId, TNifProgressBuf& aProgress, TRequestStatus& aStatus, TUint aSelectedProgress = KConnProgressDefault);
1100 IMPORT_C void CancelProgressNotification();
1101 IMPORT_C void CancelProgressNotification(TSubConnectionUniqueId aSubConnectionUniqueId);
1102 IMPORT_C TInt Progress(TNifProgress& aProgress);
1103 IMPORT_C TInt Progress(TSubConnectionUniqueId aSubConnectionUniqueId, TNifProgress& aProgress);
1104 IMPORT_C TInt LastProgressError(TNifProgress& aProgress);
1105 IMPORT_C void ServiceChangeNotification(TUint32& aNewISPId, TDes& aNewServiceType, TRequestStatus& aStatus);
1107
1108
1112 IMPORT_C TInt GetIntSetting(const TDesC& aSettingName, TUint32& aValue);
1113
1117 IMPORT_C TInt GetBoolSetting(const TDesC& aSettingName, TBool& aValue);
1118
1122 IMPORT_C TInt GetDesSetting(const TDesC& aSettingName, TDes8& aValue);
1123
1127 IMPORT_C TInt GetDesSetting(const TDesC& aSettingName, TDes16& aValue);
1128
1132 IMPORT_C TInt GetLongDesSetting(const TDesC& aSettingName, TDes& aValue);
1133
1134
1135 IMPORT_C TInt GetParameters(ESock::CCommsDataObjectBase& aDataObject);
1136 IMPORT_C TInt SetParameters(ESock::CCommsDataObjectBase& aDataObject);
1137
1138 IMPORT_C TInt Name(TName& aName);
1139
1140 IMPORT_C TInt EnumerateConnections(TUint& aCount);
1141 IMPORT_C TInt GetConnectionInfo(TUint aIndex, TDes8& aConnectionInfo);
1142
1143 IMPORT_C void AllInterfaceNotification(TDes8& aNotification, TRequestStatus& aStatus);
1144 IMPORT_C void CancelAllInterfaceNotification();
1145
1146 IMPORT_C void Ioctl(TUint aOptionLevel, TUint aOptionName, TRequestStatus& aStatus, TDes8* aDesc);
1147 IMPORT_C void Ioctl(TUint aOptionLevel, TUint aOptionName, TRequestStatus& aStatus);
1148 IMPORT_C void CancelIoctl();
1149 IMPORT_C TInt Control(TUint aOptionLevel, TUint aOptionName, TDes8& aOption);
1150 IMPORT_C TInt GetOpt(TUint aOptionLevel, TUint aOptionName, TInt& aOption);
1151 IMPORT_C TInt SetOpt(TUint aOptionLevel, TUint aOptionName, TInt aOption = 0);
1152
1153 IMPORT_C TInt Attach(const TDesC8& aConnectionInfo, TConnAttachType aAttachType);
1154
1155 IMPORT_C TInt EnumerateSubConnections(TUint& aCount);
1156 IMPORT_C TInt GetSubConnectionInfo(TDes8& aSubConnectionInfo);
1157 IMPORT_C TInt GetSubConnectionInfo(TUint aIndex, TDes8& aSubConnectionInfo);
1158 IMPORT_C void AllSubConnectionNotification(TSubConnectionNotificationBuf& aSubConnectionEvent, TRequestStatus& aStatus);
1159 IMPORT_C void CancelAllSubConnectionNotification();
1160
1161 IMPORT_C void DataTransferredRequest(TPckg<TUint>& aUplinkVolume, TPckg<TUint>& aDownlinkVolume, TRequestStatus& aStatus);
1162 IMPORT_C void DataTransferredRequest(TSubConnectionUniqueId aSubConnectionUniqueId, TPckg<TUint>& aUplinkVolume, TPckg<TUint>& aDownlinkVolume, TRequestStatus& aStatus);
1163 IMPORT_C void DataTransferredCancel();
1164 IMPORT_C void DataTransferredCancel(TSubConnectionUniqueId aSubConnectionUniqueId);
1165 IMPORT_C void DataSentNotificationRequest(TUint aThreshold, TPckg<TUint>& aUplinkVolume, TRequestStatus& aStatus);
1166 IMPORT_C void DataSentNotificationRequest(TSubConnectionUniqueId aSubConnectionUniqueId, TUint aThreshold, TPckg<TUint>& aUplinkVolume, TRequestStatus& aStatus);
1168 IMPORT_C void DataSentNotificationCancel(TSubConnectionUniqueId aSubConnectionUniqueId);
1169 IMPORT_C void DataReceivedNotificationRequest(TUint aThreshold, TPckg<TUint>& aDownlinkVolume, TRequestStatus& aStatus);
1170 IMPORT_C void DataReceivedNotificationRequest(TSubConnectionUniqueId aSubConnectionUniqueId, TUint aThreshold, TPckg<TUint>& aDownlinkVolume, TRequestStatus& aStatus);
1172 IMPORT_C void DataReceivedNotificationCancel(TSubConnectionUniqueId aSubConnectionUniqueId);
1173 IMPORT_C void IsConnectionActiveRequest(TUint aSecs, TPckg<TBool>& aState, TRequestStatus& aStatus);
1174 IMPORT_C void IsConnectionActiveCancel();
1175 IMPORT_C void IsSubConnectionActiveRequest(TSubConnectionUniqueId aSubConnectionUniqueId, TUint aSecs, TPckg<TBool>& aState, TRequestStatus& aStatus);
1176 IMPORT_C void IsSubConnectionActiveCancel(TSubConnectionUniqueId aSubConnectionUniqueId);
1177
1178 TBool SameSession(TInt aSessionHandle);
1179private:
1180 TPckg<TUint32> iNewISPId;
1181 TUint32 iReserved[4];
1182 };
1184class CSubConParameterSet : public XParameterSetBase
1191 {
1192public:
1193 IMPORT_C static CSubConParameterSet* NewL(const STypeId& aTypeId);
1194 virtual ~CSubConParameterSet();
1196protected:
1200
1209public:
1212protected:
1213 IMPORT_C CSubConGenericParameterSet();
1223 {
1224public:
1226
1227protected:
1229 };
1230
1232class CSubConParameterBundle;
1234const TInt32 KSubConnParamsInterfaceUid = 0x10204303;
1235const TInt32 KSubConnEventInterfaceUid = 0x10204305;
1236
1237const TInt32 KSubConnGenericParamsImplUid = 0x10204304;
1238const TInt32 KSubConnGenericEventsImplUid = 0x10204306;
1239
1240const TUint32 KSubConGlobalFamily = 0;
1241const TUint32 KSubConQoSFamily = 1;
1242const TUint32 KSubConAuthorisationFamily = 2;
1244const TUint32 KSubConnContextDescrParamsFamily = 4;
1245
1246const TUint32 KSubConIPAddressInfoFamily = 5;
1247
1249const TInt32 KFlowParametersFamily = 7;
1250class RParameterFamily;
1268 {
1269public:
1270
1276 ENumValues = 3 // The number of values in this enum
1279public:
1280 IMPORT_C static CSubConParameterFamily* NewL(RSubConParameterBundle& aBundle, TUint32 aFamilyId);
1281 IMPORT_C static CSubConParameterFamily* LoadL(RSubConParameterBundle& aBundle, TPtrC8& aBuffer);
1282 IMPORT_C static CSubConParameterFamily* NewL(CSubConParameterBundle& aBundle, TUint32 aFamilyId);
1283 IMPORT_C static CSubConParameterFamily* LoadL(CSubConParameterBundle& aBundle, TPtrC8& aBuffer);
1285public:
1286 IMPORT_C virtual ~CSubConParameterFamily();
1293
1294 inline TUint32 Id();
1295
1296 IMPORT_C TUint Length() const;
1297 IMPORT_C TInt Load(TPtrC8& aDes);
1298 IMPORT_C TInt Store(TDes8& aDes) const;
1299 IMPORT_C void ClearAllParameters(TParameterSetType aType);
1305 void CopyToFamilyL(RParameterFamily& aDest) const;
1306
1311 void CopyFromFamilyL(RParameterFamily& aSrc);
1312protected:
1313 IMPORT_C explicit CSubConParameterFamily(TUint32 aFamilyId);
1314 IMPORT_C void ConstructL(RSubConParameterBundle& aBundle);
1315 IMPORT_C void ConstructL(CSubConParameterBundle& aBundle);
1317 IMPORT_C static TInt32 ExtractFamilyAndCreateBufferL(TPtrC8& aBuffer, TPtrC8& aContainerBuffer);
1318
1319private:
1320 const TUint32 iFamilyId; // This member variable is accessed by an inline function ( Id () ).
1321 RMetaDataEComContainer iGenericSets;
1322protected:
1323 RMetaDataEComContainer iExtensionSets[ENumValues];
1324
1325 };
1326
1327class RParameterFamilyBundle;
1342 {
1343public:
1344 IMPORT_C RSubConParameterBundle();
1345 IMPORT_C void Close();
1346
1347 IMPORT_C TUint Length() const;
1348 IMPORT_C TInt Load(const TDesC8& aDes);
1349 IMPORT_C TInt Store(TDes8& aDes) const;
1350 IMPORT_C void AddFamilyL(CSubConParameterFamily* aFamily);
1351 IMPORT_C CSubConParameterFamily* FindFamily(TUint32 aFamilyId);
1358 void CopyToFamilyBundleL(RParameterFamilyBundle& aDest) const;
1364 void CopyFromFamilyBundleL(RParameterFamilyBundle& aSrc);
1366protected:
1367 TInt CheckBundle() const;
1368private:
1370 RSubConParameterBundle& operator=(const RSubConParameterBundle& aBundle);
1372private:
1373 mutable CSubConParameterBundle* iBundle;
1375
1376
1378class TNotificationEventBuf : public TBuf8<KNotificationEventMaxSize>
1385 {
1386public:
1387 IMPORT_C TNotificationEventBuf();
1388 IMPORT_C ~TNotificationEventBuf();
1389
1390 IMPORT_C TBool IsGeneric() const;
1391 IMPORT_C TInt32 GroupId() const;
1392 IMPORT_C TUint32 Id() const;
1393 };
1394
1395#ifndef SYMBIAN_ADAPTIVE_TCP_RECEIVE_WINDOW
1396class CSubConNotificationEvent : public SMetaDataECom
1397#else
1398class CSubConNotificationEvent : public ESock::XEventBase
1399#endif // SYMBIAN_ADAPTIVE_TCP_RECEIVE_WINDOW
1400 {
1401public:
1402 IMPORT_C static CSubConNotificationEvent* NewL(const STypeId& aTypeId);
1403 IMPORT_C static CSubConNotificationEvent* NewL(const TNotificationEventBuf& aEventBuffer);
1404
1405 IMPORT_C TBool IsGeneric() const;
1406 IMPORT_C TInt32 GroupId() const;
1407 IMPORT_C TUint32 Id() const;
1409private:
1412class TSubConnOpen
1415public:
1417 enum TSubConnType
1419 EAttachToDefault, // will attach to the default sub connection
1420 ECreateNew, // will create a new sub connection
1421
1422 //private extension to subconnection openning modes below:
1428 TInt iReserved;
1429 };
1430
1431class RSubConnection : public RCommsSubSession
1442public:
1443 friend class RConnection;
1444
1446 {
1448 ECreateNew,
1450 };
1452 struct TEventFilter
1453 {
1454 inline TEventFilter(TInt32 aEventGroupId = KSubConnGenericEventsImplUid, TUint32 aEventMask = 0xffffffff);
1455 TInt32 iEventGroupUid;
1456 TUint32 iEventMask;
1457 };
1458
1459public:
1460 // Sub Connection Management
1461 IMPORT_C RSubConnection();
1462 IMPORT_C TInt Open(RSocketServ& aServer, TSubConnType aSubConnType, RConnection& aConnection);
1463 IMPORT_C void Close();
1464 IMPORT_C void Start(TRequestStatus& aStatus);
1465 IMPORT_C TInt Start();
1466 IMPORT_C TInt Stop();
1467
1468 // Socket Management
1469 IMPORT_C void Add(RSocket& aSocket, TRequestStatus& aStatus);
1470 IMPORT_C void Remove(RSocket& aSocket, TRequestStatus& aStatus);
1471
1472 // QoS Properties (legacy bundles - to be deprecated)
1473 IMPORT_C TInt SetParameters(const RSubConParameterBundle& aParametersSet);
1474 IMPORT_C TInt GetParameters(RSubConParameterBundle& aParametersSet);
1476 // QoS Properties (new prototype bundles)
1477 IMPORT_C TInt SetParameters(const RParameterFamilyBundle& aParametersSet);
1478 IMPORT_C TInt GetParameters(RParameterFamilyBundle& aParametersSet);
1480 // Event Notification
1481 IMPORT_C void EventNotification(TNotificationEventBuf& aEventBuffer, TBool aGenericEventsOnly, TRequestStatus& aStatus);
1482 IMPORT_C void EventNotification(TNotificationEventBuf& aEventBuffer, TEventFilter aEventFilterList[], TUint aEventListLength, TRequestStatus& aStatus);
1484
1485 // Generic Control
1486 IMPORT_C TInt Control(TUint aOptionLevel, TUint aOptionName, TDes8& aOption);
1487
1488 //
1489 // IMPORT_C TInt Stop(TConnStopType aStopType);
1490 // IMPORT_C void ProgressNotification(TNifProgressBuf& aProgress, TRequestStatus& aStatus, TUint aSelectedProgress = KConnProgressDefault);
1491 // IMPORT_C void CancelProgressNotification();
1492 // IMPORT_C TInt Progress(TNifProgress& aProgress);
1493 // IMPORT_C void IsSubConnectionActiveRequest(TUint aSecs, TPckg<TBool>& aState, TRequestStatus& aStatus);
1494 // IMPORT_C void IsSubConnectionActiveCancel();
1495 //
1496
1497 TBool SameSession(TInt aSessionHandle);
1499private:
1500 IMPORT_C TInt Open(RSocketServ& aServer, TSubConnOpen::TSubConnType aSubConnType, RConnection& aConnection);
1501
1502 //Note : Not used anywhere else in the code, kept in order to avoid the BC Break
1503 TInt iSpare;
1504};
1505
1506
1507class ByteOrder
1511 {
1512public:
1513 IMPORT_C static TUint32 Swap32(TUint32 aVal);
1514 IMPORT_C static TUint16 Swap16(TUint16 aVal);
1515 inline static TUint16 Swap16(TUint aVal);
1516 };
1517
1518class BigEndian
1523public:
1524 IMPORT_C static TUint32 Get32(const TUint8* aPtr);
1525 IMPORT_C static TUint16 Get16(const TUint8* aPtr);
1526 IMPORT_C static void Put32(TUint8* aPtr, TUint32 aVal);
1527 IMPORT_C static void Put16(TUint8* aPtr, TUint16 aVal);
1529
1530class LittleEndian
1535public:
1536 IMPORT_C static TUint32 Get32(const TUint8* aPtr);
1537 IMPORT_C static TUint16 Get16(const TUint8* aPtr);
1538 IMPORT_C static void Put32(TUint8* aPtr, TUint32 aVal);
1539 IMPORT_C static void Put16(TUint8* aPtr, TUint16 aVal);
1540 };
1541
1542class TAccessPointInfo
1547 {
1548public:
1549 TAccessPointInfo(TUint aApId = 0);
1550
1551 TUint AccessPoint() const;
1552 void SetAccessPoint(TUint aAccessPoint);
1554 TBool operator== (const TAccessPointInfo& aRhs) const;
1555private:
1556 TUint iAccessPointId;
1557 };
1558
1559
1560#ifndef SYMBIAN_ENABLE_SPLIT_HEADERS
1561#include <es_sock_internal.h>
1562#include <es_sock_partner.h>
1563#endif
1565#include <es_sock.inl>
1566
1567#endif //__ES_SOCK_H__
1568
Inserts and extracts integers in big-endian format.
Definition es_sock.h:1666
static IMPORT_C void Put16(TUint8 *aPtr, TUint16 aVal)
static IMPORT_C TUint32 Get32(const TUint8 *aPtr)
static IMPORT_C void Put32(TUint8 *aPtr, TUint32 aVal)
static IMPORT_C TUint16 Get16(const TUint8 *aPtr)
Reverses the byte order in 16 and 32-bit values.
Definition es_sock.h:1652
static IMPORT_C TUint32 Swap32(TUint32 aVal)
Reverses the order of the bytes in a 32-bit value.
static IMPORT_C TUint16 Swap16(TUint16 aVal)
Reverses the order of the bytes in a 16-bit value.
Container Base Class.
Definition e32base.h:60
Base class for extended RSubConnection parameter sets.
Definition es_sock.h:1348
IMPORT_C CSubConExtensionParameterSet()
IMPORT_C ~CSubConExtensionParameterSet()
Base class for generic RSubConnection parameter sets.
Definition es_sock.h:1330
IMPORT_C CSubConGenericParameterSet()
IMPORT_C ~CSubConGenericParameterSet()
IMPORT_C TUint32 Id() const
static IMPORT_C CSubConNotificationEvent * NewL(const STypeId &aTypeId)
IMPORT_C TBool IsGeneric() const
IMPORT_C TInt32 GroupId() const
Container of RSubConnection parameter sets.
Definition es_sock.h:1396
IMPORT_C void AddExtensionSetL(CSubConExtensionParameterSet &aExtensionSet, TParameterSetType aType)
Adds an extension parameter set to a sub-connection parameter set family.
IMPORT_C TInt Store(TDes8 &aDes) const
Instructs this sub-connection family to create a serialised version of itself and append it to the bu...
IMPORT_C CSubConExtensionParameterSet * FindExtensionSet(TUid aSetId, TParameterSetType aType)
Searches a sub-connection parameter family for an extension parameter set.
IMPORT_C void ClearAllParameters(TParameterSetType aType)
Clears (removes and deletes) all parameter sets with the type specified.
TUint32 Id()
Fetch the identity of the sub-connection parameter family.
static IMPORT_C CSubConParameterFamily * NewL(RSubConParameterBundle &aBundle, TUint32 aFamilyId)
Creates a new sub-connection parameter set family.
RMetaDataEComContainer iExtensionSets[ENumValues]
Definition es_sock.h:1451
static IMPORT_C CSubConParameterFamily * LoadL(RSubConParameterBundle &aBundle, TPtrC8 &aBuffer)
Creates a new sub-connection parameter set family from a buffer containing the serialised object.
IMPORT_C CSubConGenericParameterSet * GetGenericSet(TParameterSetType aType)
Accessor for the sub-connection generic parameter set of a family.
IMPORT_C TInt Load(TPtrC8 &aDes)
Instructs this sub-connection family to set its members based on the serialiesd data in the buffer pa...
IMPORT_C void SetGenericSetL(CSubConGenericParameterSet &aGenericSet, TParameterSetType aType)
Assigns the generic parameter set of a sub-connection parameter set family.
void CopyToFamilyL(RParameterFamily &aDest) const
Copy the parameters of this CSubConParameterFamily to a RParameterFamily.
virtual IMPORT_C ~CSubConParameterFamily()
Sub-connection parameter family destructor.
IMPORT_C TUint Length() const
Calculates the length of buffer required to serialise this parameter set family.
IMPORT_C void ConstructL(RSubConParameterBundle &aBundle)
Set up the sub-connection family with empty sets.
static IMPORT_C TInt32 ExtractFamilyAndCreateBufferL(TPtrC8 &aBuffer, TPtrC8 &aContainerBuffer)
Used internally to extract the family id for the descriptor storing the serialised version of this ob...
void CopyFromFamilyL(RParameterFamily &aSrc)
Copy the parameters of this CSubConParameterFamily from a RParameterFamily.
Base class for all RSubConnection parameter sets.
Definition es_sock.h:1310
static IMPORT_C CSubConParameterSet * NewL(const STypeId &aTypeId)
virtual ~CSubConParameterSet()
Inserts and extracts integers in little-endian format.
Definition es_sock.h:1681
static IMPORT_C void Put32(TUint8 *aPtr, TUint32 aVal)
static IMPORT_C TUint16 Get16(const TUint8 *aPtr)
static IMPORT_C void Put16(TUint8 *aPtr, TUint16 aVal)
static IMPORT_C TUint32 Get32(const TUint8 *aPtr)
The management interface for a network connection or subconnection.
Definition es_sock.h:1164
IMPORT_C void DataSentNotificationCancel()
Cancels a request for the amount of data sent on this connection, as issued by DataSentNotificationRe...
IMPORT_C void DataReceivedNotificationRequest(TUint aThreshold, TPckg< TUint > &aDownlinkVolume, TRequestStatus &aStatus)
Requests a notification after an additional aThreshold bytes have been received by this connection.
IMPORT_C void CancelAllInterfaceNotification()
Cancels a change notification request previously issued by a call to AllInterfaceNotification().
TBool SameSession(TInt aSessionHandle)
Checks that the Session Handle passed is the same as that of this RConnection.
IMPORT_C void WaitForIncoming(RSubConnection &aIncomingSubConnection, TRequestStatus &aStatus)
Subscribe for an incoming session on this connection.
IMPORT_C TInt GetConnectionInfo(TUint aIndex, TDes8 &aConnectionInfo)
Gets information about one of the currently active connections.
IMPORT_C void CancelAllSubConnectionNotification()
Cancels the request for notification to changes to the state of subconnections, made using the AllSub...
IMPORT_C void IsSubConnectionActiveRequest(TSubConnectionUniqueId aSubConnectionUniqueId, TUint aSecs, TPckg< TBool > &aState, TRequestStatus &aStatus)
Checks whether the subconnection is active or has changed state (active/inactive)
IMPORT_C void AllSubConnectionNotification(TSubConnectionNotificationBuf &aSubConnectionEvent, TRequestStatus &aStatus)
Requests notification of any change in the state of any of the subconnections belonging to this RConn...
IMPORT_C TInt Open(RSocketServ &aSocketServer, TUint aConnectionType=KConnectionTypeDefault)
Opens a new RConnection instance.
IMPORT_C RConnection()
Connection Management Interface.
IMPORT_C void CancelWaitForIncoming()
Cancel the previous subscription for an incoming session.
IMPORT_C void CancelServiceChangeNotification()
Cancels a request for notification of change of service for the connection, as issued by ServiceChang...
IMPORT_C void IsSubConnectionActiveCancel(TSubConnectionUniqueId aSubConnectionUniqueId)
IMPORT_C TInt GetOpt(TUint aOptionLevel, TUint aOptionName, TInt &aOption)
Gets an option.
IMPORT_C TInt GetIntSetting(const TDesC &aSettingName, TUint32 &aValue)
IMPORT_C TInt GetLongDesSetting(const TDesC &aSettingName, TDes &aValue)
IMPORT_C void ServiceChangeNotification(TUint32 &aNewISPId, TDes &aNewServiceType, TRequestStatus &aStatus)
Requests service change notification from the agent.
IMPORT_C void Close()
Closes the connection.
IMPORT_C TInt EnumerateSubConnections(TUint &aCount)
Asks the server to gather information on the currently active subconnections.
IMPORT_C void Ioctl(TUint aOptionLevel, TUint aOptionName, TRequestStatus &aStatus, TDes8 *aDesc)
Get information on the connection in an asynchronous manner.
IMPORT_C TInt Stop()
Stops the entire connection by disconnecting the underlying network interface immediately,...
IMPORT_C void DataTransferredCancel()
Cancels a request for the amount of data transferred on the entire connection, issued by DataTransfer...
TConnStopType
Identifies the type of requirement for stopping the connection.
Definition es_sock.h:1179
@ EStopAuthoritative
Any sockets or host/service resolvers associated with this interface will be errored with KErrConnect...
Definition es_sock.h:1189
@ EStopNormal
Any sockets or host/service resolvers associated with this interface will be errored with KErrCancel.
Definition es_sock.h:1183
IMPORT_C TInt GetBoolSetting(const TDesC &aSettingName, TBool &aValue)
IMPORT_C TInt Attach(const TDesC8 &aConnectionInfo, TConnAttachType aAttachType)
Attaches the RConnection object to an existing interface.
IMPORT_C TInt Progress(TNifProgress &aProgress)
Obtains the current progress information for the connection.
IMPORT_C TInt EnumerateConnections(TUint &aCount)
Enumerates the number of currently active interfaces.
IMPORT_C void DataSentNotificationRequest(TUint aThreshold, TPckg< TUint > &aUplinkVolume, TRequestStatus &aStatus)
Requests a notification after an additional aThreshold bytes have been sent by the entire connection.
IMPORT_C void AllInterfaceNotification(TDes8 &aNotification, TRequestStatus &aStatus)
Requests asynchronous change notification for all interfaces.
IMPORT_C TInt LastProgressError(TNifProgress &aProgress)
Obtains information about the last Progress() call which failed with an error.
IMPORT_C void ProgressNotification(TNifProgressBuf &aProgress, TRequestStatus &aStatus, TUint aSelectedProgress=KConnProgressDefault)
Requests asynchronous progress notification for the connection.
IMPORT_C void DataReceivedNotificationCancel()
Cancels a request (issued by DataReceivedNotificationRequest ()) for the amount of data received by t...
IMPORT_C TInt Control(TUint aOptionLevel, TUint aOptionName, TDes8 &aOption)
Gets detailed information on connection clients and sockets.
IMPORT_C void CancelProgressNotification()
Cancels a request for progress notification for the connection, as issued by ProgressNotification().
IMPORT_C void DataTransferredRequest(TPckg< TUint > &aUplinkVolume, TPckg< TUint > &aDownlinkVolume, TRequestStatus &aStatus)
Gets the amount of data that has been transferred by the entire connection.
IMPORT_C TInt GetDesSetting(const TDesC &aSettingName, TDes8 &aValue)
IMPORT_C TInt Name(TName &aName)
Gets the unique name of an RConnection.
IMPORT_C void IsConnectionActiveRequest(TUint aSecs, TPckg< TBool > &aState, TRequestStatus &aStatus)
Checks whether the connection is active or inactive.
IMPORT_C TInt SetParameters(ESock::CCommsDataObjectBase &aDataObject)
Speculative method - Not yet supported Do not call this function, it has ony been introduced for symm...
IMPORT_C TInt SetOpt(TUint aOptionLevel, TUint aOptionName, TInt aOption=0)
Sets an option.
virtual IMPORT_C ~RConnection()
Empty destructor.
IMPORT_C TInt GetSubConnectionInfo(TDes8 &aSubConnectionInfo)
Gets information about one of the currently active subconnections.
IMPORT_C void IsConnectionActiveCancel()
IMPORT_C void CancelIoctl()
Cancel any outstanding Ioctl request.
TConnAttachType
Identifies the intended use of the connection.
Definition es_sock.h:1168
@ EAttachTypeMonitor
The system control type of application wishes to monitor the state of the connection without otherwis...
Definition es_sock.h:1175
@ EAttachTypeNormal
The application wishes to use the connection for normal data transfer, and the idle timers will take ...
Definition es_sock.h:1171
IMPORT_C TInt GetParameters(ESock::CCommsDataObjectBase &aDataObject)
IMPORT_C TInt Start()
Start a connection synchonously using the default connection preferences.
Provides an interface to host name resolution services, such as DNS, that may be provided by particul...
Definition es_sock.h:1001
IMPORT_C void GetByAddress(const TSockAddr &anAddr, TNameEntry &aResult, TRequestStatus &aStatus)
Get host by address (as get by name)
IMPORT_C void Close()
Closes a name resolution service.
IMPORT_C void Cancel()
Cancels any outstanding asynchronous calls, which will return with error code KErrCancel.
IMPORT_C void QueryGetNext(TDes8 &aResult, TRequestStatus &aStatus)
Get the next query result.
IMPORT_C TInt SetOpt(TUint anOptionName, TUint anOptionLevel, const TDesC8 &anOption=TPtrC8(NULL, 0))
IMPORT_C TInt Open(RSocketServ &aSocketServer, TUint anAddrFamily, TUint aProtocol)
Initialises a name resolution service provided by a particular protocol.
IMPORT_C void Query(const TDesC8 &aQuery, TDes8 &aResult, TRequestStatus &aStatus)
Protocol - independent query.
IMPORT_C TInt SetHostName(const TDesC &aName)
IMPORT_C TInt GetHostName(TDes &aName)
Gets the name of the local host.
IMPORT_C void GetByName(const TDesC &aName, TNameEntry &aResult, TRequestStatus &aStatus)
Resolves a machine name to a TSockAddress asynchronously.
IMPORT_C void Next(TNameEntry &aResult, TRequestStatus &aStatus)
Get the next response if there is more than one response for a given host name (alias list)
Provides an interface to network databases, such as LM-IAS with IrDA, that may be provided by particu...
Definition es_sock.h:1077
IMPORT_C void Remove(const TDesC8 &anItem, TRequestStatus &aStat)
Removes a record from the database asynchronously.
IMPORT_C void Close()
Closes a database access service.
IMPORT_C void Query(const TDesC8 &aQuery, TDes8 &aResult, TRequestStatus &aStat)
Makes a query to the database asynchronously.
IMPORT_C TInt Open(RSocketServ &aSocketServer, TUint anAddrFamily, TUint aProtocol)
Initialises a database access service provided by a particular protocol.
IMPORT_C void Cancel()
Cancels any outstanding asynchronous calls, which will return with error code KErrCancel.
IMPORT_C void Add(const TDesC8 &anItem, TRequestStatus &aStat)
Adds a record to the database asynchronously.
Provides an interface to resolver service names and ports.
Definition es_sock.h:1042
IMPORT_C void GetByNumber(const TUint aPort, TDes &aName, TRequestStatus &aStatus)
Gets the name of the service asynchronously.
IMPORT_C void Cancel()
Cancels any pending request.
IMPORT_C void RemoveService(const TDesC &aName, const TUint &aPort, TRequestStatus &aStatus)
Removes a service asynchronously.
IMPORT_C TInt Open(RSocketServ &aSocketServer, TUint anAddrFamily, TUint sockType, TUint aProtocol)
set up the sub session - unlike name resolvers and net databases, services can be socket type specifi...
IMPORT_C void Close()
Closes a service resolver service.
IMPORT_C void GetByName(const TDesC &aName, TPortNum &aPort, TRequestStatus &aStatus)
Gets a service by name asynchronously.
IMPORT_C void RegisterService(const TDesC &aName, const TUint &aPort, TRequestStatus &aStatus)
Registers a new service asynchronously.
Client-side handle to a session with a server.
Definition e32std.h:4611
Provides the Connect() function to create an IPC communication channel to the socket server.
Definition es_sock.h:800
IMPORT_C void SetExclusiveMode(TRequestStatus &aStatus)
Set this session as the socket server exclusive session.
IMPORT_C TInt __DbgCheckHeap(TInt aCount)
Set a heap mark in the socket server.
IMPORT_C TVersion Version() const
Gets the version number of this client.
IMPORT_C TInt __DbgControl(const ESockDebug::TControlMsg &aRequestMsg)
General purpose control message for esock debug, self dispatching messages to be thrown over it.
IMPORT_C TInt __DbgMbufFreeSpace()
Get the amount of free space in the MBuf manager.
IMPORT_C TInt __DbgCheckMbuf(TInt asize)
Set the Mbuf pool limit.
IMPORT_C RSocketServ()
Default Constructor.
IMPORT_C TInt __DbgSetMbufPoolLimit(TInt asize)
Set the Mbuf pool limit.
IMPORT_C TInt __DbgMbufTotalSpace()
Get the amount of free space in the MBuf manager.
IMPORT_C void ClearExclusiveMode()
Clear exclusive mode for this session PLEASE NOTE: This API is currently unsupported,...
IMPORT_C void StopProtocol(TUint anAddrFamily, TUint aSockType, TUint aProtocol, TRequestStatus &aStatus)
Unload a protocol asynchronously - note it will fail if there are any resources open.
IMPORT_C TInt __DbgMarkHeap()
Set a heap mark in the socket server.
IMPORT_C TInt FindProtocol(const TProtocolName &aName, TProtocolDesc &aProtocol)
Gets information about a specific protocol, identified by it's name.
IMPORT_C TInt __DbgMarkEnd(TInt aCount)
Set a heap mark in the socket server.
IMPORT_C TInt Connect(TUint aMessageSlots=(TUint) -1)
Opens a session to the socket server.
IMPORT_C TInt InstallExtension(const TDesC &aDllName, const TDesC &aArgs=TPtrC())
Install an Esock Extension.
IMPORT_C TInt __DbgFailNextMbuf(TInt aCount)
Set a Mbuf mark in the socket server.
IMPORT_C TInt NumProtocols(TUint &aCount)
Gets the number of protocols the socket server is currently aware of.
IMPORT_C TInt GetProtocolInfo(TUint anIndex, TProtocolDesc &aProtocol)
Gets information about a specific protocol.
IMPORT_C TInt __DbgFailNext(TInt aCount)
Set a heap mark in the socket server.
IMPORT_C TBool __DbgCheckFailNext() const
Empty release implementation.
IMPORT_C void StartProtocol(TUint anAddrFamily, TUint aSockType, TUint aProtocol, TRequestStatus &aStatus)
Loads a specified protocol asynchronously.
Provides a client endpoint to a protocol.
Definition es_sock.h:855
IMPORT_C TInt GetDisconnectData(TDes8 &aDesc)
Gets data for use in the disconnection of a socket, namely the remote name of the connected socket.
IMPORT_C void CancelSend()
Cancels an outstanding Send() operation.
IMPORT_C TInt GetOpt(TUint anOptionName, TUint anOptionLevel, TDes8 &anOption)
Gets a socket option.
IMPORT_C TInt Bind(TSockAddr &anAddr)
Sets the local address of a socket.
IMPORT_C void CancelRecv()
Cancels an outstanding Recv() operation.
IMPORT_C void Shutdown(TShutdown aHow, TRequestStatus &aStatus)
Shuts down a connected socket - asynchronous.
IMPORT_C void RemoteName(TSockAddr &anAddr)
Gets the remote name of a connected socket.
IMPORT_C void Recv(TDes8 &aDesc, TUint flags, TRequestStatus &aStatus)
Receives data from a remote host, allowing flags for protocol specific information.
IMPORT_C void Close()
Closes a socket.
IMPORT_C TInt SetOpt(TUint anOptionName, TUint anOptionLevel, const TDesC8 &anOption=TPtrC8(NULL, 0))
Sets a socket option.
IMPORT_C void Write(const TDesC8 &aDesc, TRequestStatus &aStatus)
Sends data to a remote host.
IMPORT_C TInt Open(RSocketServ &aServer, TUint addrFamily, TUint sockType, TUint protocol)
Opens an implicit socket by creating a new subsession to the socket server.
IMPORT_C void RecvFrom(TDes8 &aDesc, TSockAddr &anAddr, TUint flags, TRequestStatus &aStatus)
Receives data from a remote host through a (possibly) unconnected socket and returns a source address...
IMPORT_C void CancelAll()
Cancels all outstanding operations.
IMPORT_C void Ioctl(TUint aCommand, TRequestStatus &aStatus, TDes8 *aDesc=NULL, TUint aLevel=KLevelUnspecified)
Applies an asynchronous I/O control operation on a socket.
IMPORT_C void Connect(TSockAddr &anAddr, TRequestStatus &aStatus)
Connects to a remote host asynchronously.
IMPORT_C TInt Transfer(RSocketServ &aServer, const TDesC &aName)
Transfers a socket from one socket server session to another.
IMPORT_C void LocalName(TSockAddr &anAddr)
Gets the local address of a bound socket.
IMPORT_C void CancelConnect()
Cancels an outstanding connect operation.
IMPORT_C TInt Info(TProtocolDesc &aProtocol)
Gets information in the protocol description for the protocol which a socket is opened on.
IMPORT_C void CancelWrite()
Cancels an outstanding Write() operation.
IMPORT_C RSocket()
Default Constructor.
IMPORT_C TUint LocalPort()
Gets the local port number of a bound socket.
TShutdown
Argument to RSocket::Shutdown() specifying how abruptly the shutdown occurs.
Definition es_sock.h:861
@ EStopInput
Stop socket input and complete when output is stopped.
Definition es_sock.h:865
@ EImmediate
Stop socket input/output and complete (abortive close).
Definition es_sock.h:869
@ ENormal
Complete when socket output/input stopped.
Definition es_sock.h:863
@ EStopOutput
Stop socket output and complete when input is stopped.
Definition es_sock.h:867
IMPORT_C void RecvOneOrMore(TDes8 &aDesc, TUint flags, TRequestStatus &aStatus, TSockXfrLength &aLen)
Receives data from a remote host and completes when data is available.
IMPORT_C void CancelRead()
Cancels an outstanding Read() operation.
IMPORT_C void Accept(RSocket &aBlankSocket, TRequestStatus &aStatus)
Facilitates a client/server connection from a remote socket.
IMPORT_C void SendTo(const TDesC8 &aDesc, TSockAddr &anAddr, TUint flags, TRequestStatus &aStatus)
Sends data to a remote host through a (possibly) unconnected socket to a specified destination addres...
IMPORT_C void Read(TDes8 &aDesc, TRequestStatus &aStatus)
Receives data from a remote host.
IMPORT_C void CancelAccept()
Cancels an outstanding accept operation.
IMPORT_C TInt SetLocalPort(TInt aPort)
Sets the local port of a socket.
IMPORT_C void Send(const TDesC8 &aDesc, TUint someFlags, TRequestStatus &aStatus)
Sends data to a remote host on a connected socket with options set by protocol specific flags.
IMPORT_C TInt Name(TName &aName)
Gets a unique system name for the socket.
IMPORT_C void CancelIoctl()
Cancels an outstanding Ioctl() operation.
IMPORT_C TInt Listen(TUint qSize)
Sets up a socket to listen for incoming connections.
Container for (bundle of) SubConnection parameter families.
Definition es_sock.h:1473
IMPORT_C void AddFamilyL(CSubConParameterFamily *aFamily)
Add a sub-connection parameter family to the bundle.
IMPORT_C void Close()
Close the parameter bundle handle.
void CopyFromFamilyBundleL(RParameterFamilyBundle &aSrc)
Copy the contents of an RParameterFamilyBundle to this RSubConParameterBundle.
IMPORT_C TInt Load(const TDesC8 &aDes)
Instructs this sub-connection bundle to set its members based on the serialiesd data in the buffer pa...
TInt CheckBundle() const
Check to see if the handle has a heap object.
IMPORT_C RSubConParameterBundle()
Empty sub-connection parameter bundle constructor.
IMPORT_C CSubConParameterFamily * FindFamily(TUint32 aFamilyId)
Search the sub-connection parameter bundle for a parameter family.
IMPORT_C TInt Store(TDes8 &aDes) const
Instructs this sub-connection parameter bundle to create a serilised version of itself and append it ...
IMPORT_C TUint Length() const
Calculates the length of buffer required to serialise this parameter set bundle.
void CopyToFamilyBundleL(RParameterFamilyBundle &aDest) const
Copy the contents of this parameter bundle to a RParameterFamilyBundle.
IMPORT_C void ClearAllParameters(CSubConParameterFamily::TParameterSetType aType)
Clears (removes and deletes) all parameter sets with the type specified (delegated to the families)
A Sub-Connection, a channel within a Connection.
Definition es_sock.h:1579
IMPORT_C void CancelEventNotification()
Cancel an outstanding Event Notification request.
IMPORT_C TInt SetParameters(const RSubConParameterBundle &aParametersSet)
Set Parameters of the sub-connection.
IMPORT_C TInt Control(TUint aOptionLevel, TUint aOptionName, TDes8 &aOption)
IMPORT_C TInt GetParameters(RSubConParameterBundle &aParametersSet)
Fetch the sub-connection's current parameters (Requested, Acceptable and Granted)
IMPORT_C void EventNotification(TNotificationEventBuf &aEventBuffer, TBool aGenericEventsOnly, TRequestStatus &aStatus)
Requests asynchronous event notification for the sub-connection.
IMPORT_C void Close()
Closes the sub-connection.
IMPORT_C TInt Start()
Unused.
IMPORT_C TInt Stop()
Unused.
IMPORT_C void Add(RSocket &aSocket, TRequestStatus &aStatus)
Associate a socket with a subconnection.
IMPORT_C TInt Open(RSocketServ &aServer, TSubConnType aSubConnType, RConnection &aConnection)
Opens a new RSubConnection instance.
IMPORT_C RSubConnection()
Empty sub-connection handle constructor.
IMPORT_C void Remove(RSocket &aSocket, TRequestStatus &aStatus)
Remove a socket from a subconnection.
TBool SameSession(TInt aSessionHandle)
Checks that the Session Handle passed is the same as that of this RSubConnection.
Client-side handle to a sub-session.
Definition e32std.h:4727
Stores Access Point information.
Definition es_sock.h:1696
void SetAccessPoint(TUint aAccessPoint)
Sets the 32-bit long integer ID of the access point.
TBool operator==(const TAccessPointInfo &aRhs) const
Compares the 32-bit long integer ID of the specified object with our own.
TUint AccessPoint() const
Returns the 32-bit long integer ID of the access point.
Contains the results of name queries.
Definition es_sock.h:940
@ EPartial
Indicates a partial (truncated) host name.
Definition es_sock.h:947
THostName iName
A host name.
Definition es_sock.h:953
TNameRecord()
Trivial C++ constructor.
TInt iFlags
Flags indicating some attribute about the name, i.e.
Definition es_sock.h:959
TSockAddr iAddr
An address.
Definition es_sock.h:957
Contains information describing an agent.
Definition es_sock.h:190
TVersion iVersion
This class Contains version information.
Definition es_sock.h:193
TName iName
This class Defines a modifiable buffer descriptor that can contain the name of a reference counting o...
Definition es_sock.h:196
Contains progress information on a dial-up connection.
Definition es_sock.h:173
TNifProgress()
It sets the iStage data member to 0 and the iError data member to KErrNone.
TInt iStage
Definition es_sock.h:178
TInt iError
Definition es_sock.h:179
TBool operator==(const TNifProgress &aRHS) const
Buffer for Sub-connection event notiifcation.
Definition es_sock.h:1517
IMPORT_C TUint32 Id() const
Provides the sub-type Id of the event.
IMPORT_C TInt32 GroupId() const
Provides the group id (Uid) of the event.
IMPORT_C TBool IsGeneric() const
Check whether an event is a generic event (not an extension)
IMPORT_C TNotificationEventBuf()
IMPORT_C ~TNotificationEventBuf()
Packages an object into a modifiable buffer descriptor.
Definition e32cmn.h:1807
Packages a modifiable pointer descriptor which represents an object of specific type.
Definition e32cmn.h:1778
Indicates the completion status of a request made to a service provider.
Definition e32cmn.h:2243
Hint to the Socket Server on what will be the principal usage of the connection.
Definition es_sock.h:145
TUint iAddrFamily
The protocol's address family.
Definition es_sock.h:150
TUint iProtocol
The protocol type.
Definition es_sock.h:152
TUint iReserved3
Reserved.
Definition es_sock.h:160
TUint iReserved
Reserved.
Definition es_sock.h:154
IMPORT_C TSessionPref()
Default Constructor, makes sure that member data doesn't contain unnitialised values.
TUint iReserved4
Reserved.
Definition es_sock.h:162
TUint iReserved1
Reserved.
Definition es_sock.h:156
TUint iReserved2
Reserved.
Definition es_sock.h:158
Represents an end point address.
Definition es_sock.h:258
IMPORT_C void SetPort(TUint aPort)
Sets the address port of an address.
IMPORT_C TSockAddr()
Default constructor initialises the address to be zero-filled.
IMPORT_C void SetFamily(TUint aFamily)
Sets the address family of an address.
IMPORT_C TUint Family() const
Gets the address family and thereby the type of address.
IMPORT_C TUint Port() const
Gets the port value.
IMPORT_C void SetUserLen(TInt aLen)
Sets the length of data it appends after the base class' data.
IMPORT_C TInt GetUserLen()
Gets the number of bytes a derived class has set beyond the SSockAddr part of the address.
TUint8 * UserPtr() const
Gets an offset to place data after the base class data.
IMPORT_C TBool CmpPort(const TSockAddr &anAddr) const
Compare two ports.
TSubConnType
Defines the type of a subconnection.
Definition es_sock.h:1554
TInt iReserved
Definition es_sock.h:1564
TSubConnType iType
Definition es_sock.h:1562
A globally unique 32-bit number.
Definition e32cmn.h:1959
Contains version information.
Definition e32cmn.h:2200
NONSHARABLE_CLASS(TCleanupTrapHandler)
Implementation for a handler to work with the TRAP mechanism.
Definition e32base.h:1453
TDes8 TDes
Defines a build-independent modifiable descriptor.
Definition e32cmn.h:1387
TPtrC8 TPtrC
Defines a build-independent non-modifiable pointer descriptor.
Definition e32cmn.h:1366
TDesC8 TDesC
Defines a build-independent non-modifiable descriptor.
Definition e32cmn.h:1345
_LIT8(SOCKET_SERVER_MAIN_MODULE_NAME, "ESock_Main")
Canonical names for the core ESOCKSVR modules.
const TUint KSIDatagram
The same as message based.
Definition es_sock.h:506
const TUint KSOUrgentDataOffset
Getting only: retrieve the urgent data offset (only for stream protocols that support urgent data).
Definition es_sock.h:373
const TUint KNSDynamicAddressing
Addressing is dynamic - i.e.
Definition es_sock.h:575
TPckgBuf< TInt > TSockXfrLength
Used in RSocket read and write calls to pass the length of data read and written.
Definition es_sock.h:756
const TUint KSOSelectPoll
Getting only: gets a bitmask of flags describing the read/write/exception status of the socket.
Definition es_sock.h:366
const TUint KIOctlSelect
The aDesc parameter of RSocket::Ioctl() specifies a TUint containing a bitmask of Socket status const...
Definition es_sock.h:422
const TUint KSONonBlockingIO
Socket nonblocking mode.
Definition es_sock.h:356
const TUint KSIPeekData
Protocol supports peeking (looking at the data without removing it from the protocol).
Definition es_sock.h:533
const TUint KNSReserved
Definition es_sock.h:588
const TUint KSIMessageBased
The protocol is message based.
Definition es_sock.h:504
const TUint KSIGracefulClose
The protocol supports graceful close.
Definition es_sock.h:528
const TUint KSIDisconnectData
The protocol can send user data on a disconnect request.
Definition es_sock.h:516
const TUint KSIMultiPoint
The protocol supports point to multi-point connections.
Definition es_sock.h:520
const TUint KSockSelectWrite
Writing to the socket is not currently blocked by flow-control.
Definition es_sock.h:434
const TUint KSockSelectReadContinuation
Include tail of prior read datagram as available data (ie indicates next read will be with read conti...
Definition es_sock.h:438
const TUint KConnProgressDefault
Definition es_sock.h:134
const TUint KSOSendBuf
Socket send buffer size.
Definition es_sock.h:349
const TUint KSIPseudoStream
The protocol supports a stream like interface but maintains datagram boundaries.
Definition es_sock.h:510
const TUint KSocketInternalOptionBit
Definition es_sock.h:410
const TUint KSocketNoSecurity
No security.
Definition es_sock.h:599
const TUint KSIQOS
The protocol supports a quality of service metric.
Definition es_sock.h:522
const TUint KUndefinedProtocol
Undefined socket type.
Definition es_sock.h:638
const TUint KMaxSockAddrSize
Maximum sockets address size.
Definition es_sock.h:234
const TUint KSIReliable
The protocol is reliable.
Definition es_sock.h:500
const TInt KSocketBufSizeUndefined
Use default buffer size.
Definition es_sock.h:405
const TInt KSocketMessageSizeUndefined
Depends on lower layer or is dynamic.
Definition es_sock.h:616
TBuf< 0x100 > THostName
Defines a descriptor to hold a host name string.
Definition es_sock.h:658
const TUint KSIRequiresOwnerInfo
Protocol is to be informed of the identity of the client (i.e.
Definition es_sock.h:538
const TUint KNSNameRegistration
Protocol supports additions to the name database.
Definition es_sock.h:570
const TUint KSODisableTransfer
Setting only.
Definition es_sock.h:400
const TUint KMaxSubConnectionEventSize
Size of Maximum SubConnection event.
Definition es_sock.h:108
const TUint32 KSubConGlobalFamily
Definition es_sock.h:1365
const TUint KNSInfoDatabase
Protocol has another database which is defined by the protocol.
Definition es_sock.h:577
const TUint KUndefinedSockType
Undefined socket type.
Definition es_sock.h:629
const TUint KSIStreamBased
The protocol is stream based.
Definition es_sock.h:508
const TUint KNSHierarchicalNaming
Network naming is hierarchical.
Definition es_sock.h:560
const TInt KSocketMessageSizeIsStream
Reads and writes can be of any size: the data is treated as a stream.
Definition es_sock.h:614
const TInt KLevelUnspecified
Unspecified level.
Definition es_sock.h:310
TBuf< 0x20 > TServiceName
Defines a descriptor to hold a service name string.
Definition es_sock.h:656
const TUint KNSRemoteDiscovery
Addressing is dynamic and should be attempted every time before connecting (like IrDA).
Definition es_sock.h:565
const TUint KNSNameResolution
Protocol supports resolving human readable entity names into network addresses (like DNS).
Definition es_sock.h:558
const TInt KErrCannotFindProtocol
Definition es_sock.h:732
const TUint32 KSubConQoSFamily
Definition es_sock.h:1366
const TInt KErrConnectionTerminated
socket errors
Definition es_sock.h:730
const TInt KErrWouldBlock
This error is returned from operations on non-blocking sockets that cannot be completed immediately,...
Definition es_sock.h:718
const TUint32 KSubConIPAddressInfoFamily
Definition es_sock.h:1371
const TUint KSIReadOnly
The protocol is read only.
Definition es_sock.h:526
const TUint KSIReserved
Definition es_sock.h:544
const TUint KSocketInternalReadBit
Must not be set for client requests.
Definition es_sock.h:466
const TUint KSockSeqPacket
Datagrams with sequence numbers.
Definition es_sock.h:295
TPckgBuf< TInt > TPortNum
Port number on service.
Definition es_sock.h:1033
TPckgBuf< TNameRecord > TNameEntry
Packages the TNameRecord class so that it can be passed between a client and the socket server.
Definition es_sock.h:969
const TUint KSockReadPeek
Read data without consuming it, data remains in the receive queue.
Definition es_sock.h:464
const TInt KSocketDefaultBufferSize
Default buffer size.
Definition es_sock.h:407
const TInt32 KProtocolExtensionFamily
Definition es_sock.h:1373
const TUint KAFUnspec
Default (unspecified) protocol module.
Definition es_sock.h:282
TUint TSubConnectionUniqueId
SubConnection Unique Id.
Definition es_sock.h:119
const TUint KSORecvBuf
Socket receive buffer size.
Definition es_sock.h:343
const TUint KESockDefaultMessageSlots
Default number of message slots.
Definition es_sock.h:95
const TInt32 KSubConnGenericEventsImplUid
Definition es_sock.h:1363
const TUint KSockWriteSystemMask
The top 8 bits are reserved for system purposes; protocols must not define these bits.
Definition es_sock.h:453
const TInt KErrTierNotFound
Definition es_sock.h:733
const TUint KSecureSockets
Secure Sockets Layer.
Definition es_sock.h:603
const TUint KSOBlockingIO
Socket blocking mode.
Definition es_sock.h:362
TBuf8< KMaxSubConnectionEventSize > TSubConnectionNotificationBuf
Buffer for notification of any change in the state of SubConnection.
Definition es_sock.h:130
const TUint KSOSelectLastError
Getting only: retrieves the last error.
Definition es_sock.h:379
const TInt32 KSubConnGenericParamsImplUid
Definition es_sock.h:1362
const TUint KConnectionUp
Progress Notification to inform clients Connection is up This event has the same numerical values as ...
Definition es_sock.h:73
const TUint KSIUrgentData
The protocol offers an expedited data service.
Definition es_sock.h:512
const TUint KNSRequiresConnectionStartup
Protocol may request Socket Server to startup a connection on its behalf (via the KErrCompletion erro...
Definition es_sock.h:582
const TUint KSIBroadcast
The protocol supports broadcast addresses.
Definition es_sock.h:518
const TUint KSockWriteUrgent
The data to be sent is urgent and is given a higher priority than ordinary data in the send queue.
Definition es_sock.h:449
const TUint32 KSubConAuthorisationFamily
Definition es_sock.h:1367
const TInt32 KSubConnParamsInterfaceUid
Definition es_sock.h:1359
const TUint KNSHeirarchicalNaming
Definition es_sock.h:562
const TUint KSOReadBytesPending
Getting only: retrieve the number of bytes currently available for reading.
Definition es_sock.h:369
const TUint KSockSelectExcept
An error has occurred.
Definition es_sock.h:436
const TInt KNotificationEventMaxSize
Definition es_sock.h:1508
const TUint KSockSelectRead
Data is available to be read; for listening sockets, a connect is pending.
Definition es_sock.h:432
TByteOrder
Used in structure TProtocolDesc to describes the endianness of a protocol.
Definition es_sock.h:478
@ EOtherByteOrder
Other byte order.
Definition es_sock.h:484
@ ELittleEndian
Little endian.
Definition es_sock.h:482
@ EBigEndian
Big endian.
Definition es_sock.h:480
const TUint KSocketInternalWriteBit
Must not be set for client requests.
Definition es_sock.h:451
const TInt KSOLSocket
Generic socket options/commands.
Definition es_sock.h:308
const TUint KSICanReconnect
The same socket can be reconnected if it disconnects (for whatever reason).
Definition es_sock.h:530
const TInt32 KFlowParametersFamily
Definition es_sock.h:1374
const TUint KNSServiceResolution
Protocol supports service name to port number resolution.
Definition es_sock.h:568
TBuf< 0x20 > TProtocolName
Contains the name of a protocol in structure TProtocolDesc.
Definition es_sock.h:654
const TUint KSIWriteOnly
The protocol is write only.
Definition es_sock.h:524
const TInt KErrProtocolNotReady
The protocol requested for the socket was recognised but was not able to be used.
Definition es_sock.h:745
TPckgBuf< TNifProgress > TNifProgressBuf
Buffer for Network Interface Progress.
Definition es_sock.h:206
const TInt KErrConnectionContention
Definition es_sock.h:734
const TUint KSockReadContinuation
Read from datagram in a stream-like fashion (not discarding tails).
Definition es_sock.h:468
const TUint KUndefinedAddressFamily
Undefined address family.
Definition es_sock.h:646
const TUint KSockRaw
Raw socket.
Definition es_sock.h:297
const TUint KSIConnectData
The protocol can send user data on a connection request.
Definition es_sock.h:514
const TUint KSockStream
Stream socket.
Definition es_sock.h:291
const TUint KSOEnableTransfer
Setting only.
Definition es_sock.h:391
const TUint32 KSubConnCallDescrParamsFamily
Definition es_sock.h:1368
const TUint KSIConnectionLess
The protocol is connectionless.
Definition es_sock.h:498
const TInt32 KSubConnEventInterfaceUid
Definition es_sock.h:1360
const TUint KSIInOrder
The protocol guarantees in-order delivery.
Definition es_sock.h:502
const TUint KNSServiceRegistration
Protocol supports additions to the service database.
Definition es_sock.h:572
const TUint KUseEmbeddedUniqueId
Definition es_sock.h:132
const TUint KConnectionTypeDefault
Default connection type.
Definition es_sock.h:1099
const TUint32 KSubConnContextDescrParamsFamily
Definition es_sock.h:1369
const TUint KSockDatagram
Datagram socket.
Definition es_sock.h:293
const TInt KSocketMessageSizeNoLimit
Data is packet-oriented but packets can be of any size (i.e.
Definition es_sock.h:620
const TUint KSODebug
Debugging enabled or disabled .
Definition es_sock.h:337
const TUint KConnectionDown
Progress Notification to inform clients Connection is up This event has the same numerical values as ...
Definition es_sock.h:84
Socket address offsets.
Definition es_sock.h:220
TUint iPort
Port (or equivilent) number.
Definition es_sock.h:224
TUint iFamily
Address family of socket address.
Definition es_sock.h:222
Socket protocol information for use by clients.
Definition es_sock.h:669
TByteOrder iByteOrder
The byte order that the protocol uses.
Definition es_sock.h:689
TUint iProtocol
An integer specifying the specific protocol.
Definition es_sock.h:681
TUint iSecurity
A bitmask of security flags.
Definition es_sock.h:702
TUint iAddrFamily
An integer identifying the protocol's address family.
Definition es_sock.h:677
TVersion iVersion
The version of the protocol.
Definition es_sock.h:685
TUint iServiceInfo
A bit mask of service information flags.
Definition es_sock.h:693
TUint iNamingServices
A bit mask indicating if the protocol supports name resolution, service resolution,...
Definition es_sock.h:698
TUint iSockType
An integer specifying the socket type.
Definition es_sock.h:679
TInt iMessageSize
The message size of datagram protocols.
Definition es_sock.h:706
TProtocolName iName
The name of the protocol.
Definition es_sock.h:674