0
|
1 |
/*
|
|
2 |
* Copyright (c) 2004-2005 Nokia Corporation and/or its subsidiary(-ies).
|
|
3 |
* All rights reserved.
|
|
4 |
* This component and the accompanying materials are made available
|
1
|
5 |
* under the terms of the License "Eclipse Public License v1.0"
|
0
|
6 |
* which accompanies this distribution, and is available
|
|
7 |
* at the URL "http://www.eclipse.org/legal/epl-v10.html".
|
|
8 |
*
|
|
9 |
* Initial Contributors:
|
|
10 |
* Nokia Corporation - initial contribution.
|
|
11 |
*
|
|
12 |
* Contributors:
|
|
13 |
*
|
1
|
14 |
* Description:
|
0
|
15 |
*
|
|
16 |
*/
|
|
17 |
|
|
18 |
|
|
19 |
#ifndef _WSOCK_PROTOCOL_FAMILY_H_
|
|
20 |
#define _WSOCK_PROTOCOL_FAMILY_H_
|
|
21 |
|
|
22 |
#include <in_sock.h>
|
|
23 |
#include <es_prot.h>
|
|
24 |
|
|
25 |
struct TServerProtocolDesc;
|
|
26 |
struct TWinProtocolDesc: public TServerProtocolDesc
|
|
27 |
{
|
|
28 |
TUint iWinSockType; // SOCK_STREAM, SOCK_DGRAM, SOCK_RAW
|
|
29 |
TUint iWinProtocol; // IPPROTO_TCP, IPPROTO_UDP, IPPROTO_ICMP
|
|
30 |
};
|
|
31 |
|
|
32 |
class CWinsockProtocolFamily : public CProtocolFamilyBase
|
|
33 |
{
|
|
34 |
private:
|
|
35 |
TUint iAddrFamily;
|
|
36 |
|
|
37 |
public:
|
|
38 |
CWinsockProtocolFamily(TUint aAddrFamily = KAfInet);
|
|
39 |
virtual ~CWinsockProtocolFamily();
|
|
40 |
|
|
41 |
// Access to the list of protocols
|
|
42 |
static TInt ProtocolCount();
|
|
43 |
static void ProtocolNames(TDes& aNetworks);
|
1
|
44 |
static void ProtocolNamesfownetwork(TDes& aNetworks);
|
0
|
45 |
static const TServerProtocolDesc* ProtocolDesc(TInt aIndex);
|
|
46 |
|
|
47 |
// CProtocolFamilyBase
|
|
48 |
virtual TInt Install();
|
|
49 |
virtual TUint ProtocolList(TServerProtocolDesc *& aProtocolList);
|
|
50 |
virtual CProtocolBase* NewProtocolL(TUint aSockType, TUint aProtocol);
|
|
51 |
};
|
|
52 |
|
|
53 |
#endif // _WSOCK_PROTOCOL_FAMILY_H_
|