ccservices/cmsservices/cmsengine/Server/inc/cmsnotifyevent.h
changeset 0 e686773b3f54
equal deleted inserted replaced
-1:000000000000 0:e686773b3f54
       
     1 /*
       
     2 * Copyright (c) 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 *
       
    16 */
       
    17 #ifndef CMSNOTIFYEVENT_H_
       
    18 #define CMSNOTIFYEVENT_H_
       
    19 
       
    20 #include <e32base.h>
       
    21 
       
    22 enum TCmsNotifyType
       
    23 {
       
    24         EcmsNotifyPresence,
       
    25         ECmsNotifyPbk
       
    26 };
       
    27 
       
    28 class CCmsServerContact;
       
    29 
       
    30 class CCmsNotifyEvent : public CBase
       
    31     {
       
    32     public:
       
    33         
       
    34         static CCmsNotifyEvent* NewL( const TDesC& aMessage,
       
    35                                       CCmsServerContact& aContact );
       
    36         
       
    37         static CCmsNotifyEvent* NewL( const TDesC8& aMessage,
       
    38                                       CCmsServerContact& aContact );
       
    39         
       
    40         TInt Complete( TInt aMessageSlot, const RMessage2& aMessage ) const;
       
    41         
       
    42         virtual ~CCmsNotifyEvent();
       
    43         
       
    44     private:
       
    45         
       
    46         CCmsNotifyEvent( CCmsServerContact& aContact );
       
    47         
       
    48         void ConstructL( const TDesC& aMessage );
       
    49         
       
    50         void ConstructL( const TDesC8& aMessage );
       
    51         
       
    52         TInt Complete8BitL( TInt aMessageSlot,
       
    53                             TInt aClientDesLength,
       
    54                             const RMessage2& aMessage ) const;
       
    55     
       
    56         TInt Complete16BitL( TInt aMessageSlot,
       
    57                              TInt aClientDesLength,
       
    58                              const RMessage2& aMessage ) const;
       
    59         
       
    60     private:  // Data
       
    61         
       
    62         TBool                               iSent; 
       
    63         HBufC*                              iData16;
       
    64         HBufC8*                             iData8;
       
    65         CCmsServerContact&                  iContact;
       
    66     };
       
    67 
       
    68 #endif /*CMSNOTIFYEVENT_H_*/