networkprotocols/dnsproxy/dnsproxyupdateif/inc/dnsproxyupdateif.h
changeset 0 af10295192d8
equal deleted inserted replaced
-1:000000000000 0:af10295192d8
       
     1 // Copyright (c) 2008-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 
       
    16 
       
    17 
       
    18 /**
       
    19  @file
       
    20  @publishedPartner
       
    21  @released
       
    22 */
       
    23 
       
    24 #ifndef __CDNSPROXYUPDATEIF_H__
       
    25 #define __CDNSPROXYUPDATEIF_H__
       
    26 
       
    27 #include <e32base.h>
       
    28 #include <ecom/ecom.h>
       
    29 
       
    30 
       
    31 /**
       
    32 * Ecomp plugin implementation class
       
    33 */
       
    34 class CDNSProxyUpdateIf : public CBase
       
    35 {
       
    36 public:
       
    37 
       
    38 	/**
       
    39 	* Factory method for CDNSProxyUpdateIf
       
    40 	*/
       
    41    static CDNSProxyUpdateIf* NewL(TUid aUid );
       
    42 
       
    43 	/**
       
    44 	* virtual D'tor for the class.
       
    45 	*/
       
    46     virtual ~CDNSProxyUpdateIf();
       
    47 
       
    48 	/**
       
    49 	* Interface function for adding entry to the DNS DB, this need to be implemented by the deriving class.
       
    50 	*/
       
    51     virtual void AddDbEntry(const TDes8& aHostName, const TDes& aIpAddress, TRequestStatus& aStatus) = 0;
       
    52 
       
    53 	/**
       
    54 	*Interface function for removing entry from the DNS DB, this need to be implemented by the deriving class.
       
    55 	*/
       
    56     virtual void RemoveDbEntry(const TDes& aIpAddress, TRequestStatus& aStatus) = 0;
       
    57 
       
    58 
       
    59 private:
       
    60 
       
    61     //private member varible for identifying the implementations
       
    62     TUid                        iDtorIdKey;
       
    63 };
       
    64 
       
    65 /**
       
    66 * Factory method for CDNSProxyUpdateIf
       
    67 */
       
    68 inline CDNSProxyUpdateIf* CDNSProxyUpdateIf::NewL(TUid aUid )
       
    69     {
       
    70     CDNSProxyUpdateIf* self = reinterpret_cast<CDNSProxyUpdateIf*>(
       
    71     REComSession::CreateImplementationL(
       
    72         aUid,
       
    73         _FOFF(CDNSProxyUpdateIf, iDtorIdKey)));
       
    74     return self;
       
    75     }
       
    76 
       
    77 /**
       
    78 * D'Tor for ~CDNSProxyUpdateIf
       
    79 */
       
    80 inline CDNSProxyUpdateIf::~CDNSProxyUpdateIf()
       
    81     {
       
    82     REComSession::DestroyedImplementation(iDtorIdKey);
       
    83     }
       
    84 
       
    85 
       
    86 #endif //__CDNSPROXYUPDATEIF_H__
       
    87 
       
    88 
       
    89 
       
    90 
       
    91 
       
    92