ximpfw/presence/srcpresencefrontend/srcpresencemanager/presencepublishingimp.h
changeset 51 61fad867f68e
equal deleted inserted replaced
-1:000000000000 51:61fad867f68e
       
     1 /*
       
     2 * Copyright (c) 2006, 2007 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:  Implementation of MPresencePublishing
       
    15 *
       
    16 */
       
    17 
       
    18 #ifndef CPRESENCEPUBLISHINGIMP_H
       
    19 #define CPRESENCEPUBLISHINGIMP_H
       
    20 
       
    21 #include <presencepublishing.h>
       
    22 #include "ximpapiobjbase.h"
       
    23 #include "presenceapiobjbase.h"
       
    24 
       
    25 class MXIMPContextInternal;
       
    26 
       
    27 
       
    28 /**
       
    29  * MPresencePublishing API object implementation.
       
    30  *
       
    31  * @lib ximpmanager.dll
       
    32  * @since S60 v3.2
       
    33  */
       
    34 NONSHARABLE_CLASS( CPresencePublishingImp ): public CXIMPApiObjBase,
       
    35                                              public MPresencePublishing
       
    36     {
       
    37     public:
       
    38     /** The class ID. */
       
    39     enum { KClassId = PRIMP_CLSID_CPRESENCEPUBLISHINGIMP };
       
    40 
       
    41 
       
    42 public:
       
    43     static CPresencePublishingImp* NewL( MXIMPContextInternal& aContext );
       
    44     ~CPresencePublishingImp();
       
    45     
       
    46     
       
    47 public:
       
    48     CPresencePublishingImp( MXIMPContextInternal& aContext);
       
    49 
       
    50 
       
    51 public: // From MXIMPBase
       
    52 
       
    53     /**
       
    54      * Implementation of MXIMPBase interface methods
       
    55      * @see MXIMPBase
       
    56      */
       
    57     XIMPIMP_DECLARE_IF_BASE_METHODS
       
    58 
       
    59 
       
    60 public: //From MPresencePublishing
       
    61 
       
    62     TXIMPRequestId SubscribeOwnPresenceL( const MPresenceInfoFilter& aPif );
       
    63     TXIMPRequestId UnsubscribeOwnPresenceL();
       
    64     TXIMPRequestId PublishOwnPresenceL( const MPresenceInfo& aPresence );
       
    65     TXIMPRequestId SubscribePresenceWatcherListL();
       
    66     TXIMPRequestId UnsubscribePresenceWatcherListL();
       
    67     TXIMPRequestId SubscribePresenceGrantRequestListL();
       
    68     TXIMPRequestId UnsubscribePresenceGrantRequestListL();
       
    69 
       
    70 
       
    71 public: //Helpers
       
    72 
       
    73     HBufC8* PackPresenceDocLC( const MPresenceInfo& aPresence );
       
    74     HBufC8* PackPresenceInfoFilterLC( const MPresenceInfoFilter& aPif );
       
    75 
       
    76 
       
    77 private: // data
       
    78 
       
    79     /**
       
    80      * Context session proxy for accessing context server.
       
    81      * Ref.
       
    82      */
       
    83     MXIMPContextInternal& iContext;
       
    84 
       
    85     };
       
    86 
       
    87 
       
    88 #endif // CPRESENCEPUBLISHINGIMP_H