realtimenetprots/sipfw/SIP/ConnectionMgr/inc/CIcmpV4Receiver.h
changeset 0 307788aac0a8
equal deleted inserted replaced
-1:000000000000 0:307788aac0a8
       
     1 /*
       
     2 * Copyright (c) 2002-2009 Nokia Corporation and/or its subsidiary(-ies).
       
     3 * All rights reserved.
       
     4 * This component and the accompanying materials are made available
       
     5 * under the terms of "Eclipse Public License v1.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 *
       
    14 * Description:
       
    15 * Name          : CIcmpV4Receiver.h
       
    16 * Part of       : ConnectionMgr
       
    17 * Version       : SIP/4.0
       
    18 *
       
    19 */
       
    20 
       
    21 
       
    22 
       
    23 
       
    24 /**
       
    25  @internalComponent
       
    26 */
       
    27 
       
    28 #ifndef __CICMPV4RECEIVER_H__
       
    29 #define __CICMPV4RECEIVER_H__
       
    30 
       
    31 #include <e32base.h>
       
    32 #include <in_sock.h>
       
    33 
       
    34 
       
    35 // Forward declarations
       
    36 class MIcmpErrorObserver;
       
    37 
       
    38 
       
    39 class CIcmpV4Receiver : public CActive
       
    40 	{
       
    41 public:
       
    42 	static CIcmpV4Receiver* NewL(MIcmpErrorObserver& aObserver,
       
    43 								 RSocketServ& aServer);
       
    44 	void RunL();
       
    45 	void DoCancel();
       
    46 	~CIcmpV4Receiver();
       
    47 
       
    48 private:
       
    49 	CIcmpV4Receiver();
       
    50 	void Receive();
       
    51 	void ConstructL(MIcmpErrorObserver& aObserver, RSocketServ& aServer);
       
    52 	void CheckError();
       
    53 
       
    54 	//data
       
    55 	RSocket iSocket;
       
    56 	RSocketServ* iServer;
       
    57 	
       
    58 	//Buffer where data is received from the socket
       
    59 	TBuf8<64> iData;
       
    60 	TInetAddr iAddress;
       
    61 	MIcmpErrorObserver* iObserver;
       
    62 
       
    63 	RConnection* iConnection;
       
    64 
       
    65 private: //For testing purposes
       
    66 #ifdef CPPUNIT_TEST
       
    67 	friend class CIcmprecvTest;
       
    68 #endif
       
    69 	};
       
    70 
       
    71 
       
    72 #endif // end of __CICMPV4RECEIVER_H__
       
    73 
       
    74 // End of File