1.1 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
1.2 +++ b/epoc32/include/push/ccontenthandlerbase.h Tue Mar 16 16:12:26 2010 +0000
1.3 @@ -0,0 +1,96 @@
1.4 +// Copyright (c) 2001-2009 Nokia Corporation and/or its subsidiary(-ies).
1.5 +// All rights reserved.
1.6 +// This component and the accompanying materials are made available
1.7 +// under the terms of the License "Symbian Foundation License v1.0" to Symbian Foundation members and "Symbian Foundation End User License Agreement v1.0" to non-members
1.8 +// which accompanies this distribution, and is available
1.9 +// at the URL "http://www.symbianfoundation.org/legal/licencesv10.html".
1.10 +//
1.11 +// Initial Contributors:
1.12 +// Nokia Corporation - initial contribution.
1.13 +//
1.14 +// Contributors:
1.15 +//
1.16 +// Description:
1.17 +//
1.18 +
1.19 +
1.20 +
1.21 +/**
1.22 + @file
1.23 + @publishedPartner
1.24 + @released
1.25 +*/
1.26 +
1.27 +#ifndef __CCONTENTHANDLERBASE_H__
1.28 +#define __CCONTENTHANDLERBASE_H__
1.29 +
1.30 +// System includes
1.31 +//
1.32 +#include <e32base.h>
1.33 +#include <msvstd.h>
1.34 +#include <push/cpushhandlerbase.h>
1.35 +#include <push/pushmessage.h>
1.36 +
1.37 +
1.38 +// Constants
1.39 +//
1.40 +/** ECom interface UID for WAP Push Content Handler plug-ins. */
1.41 +const TUid KUidPushContentHandlerBase = { 0x101F3E5E };
1.42 +
1.43 +
1.44 +/**
1.45 +Abstract base class for WAP Push Content Handler plug-ins.
1.46 +
1.47 +A WAP Push Content Handler plug-in processes a WAP Push message that contains
1.48 +data of a specific media type. A Content Handler plug-in is loaded by a WAP Push Application
1.49 +Handler plug-in (CPushHandlerBase-derived object), and the message is passed to handle
1.50 +through HandleMessageL().
1.51 +
1.52 +A WAP Push Content Handling plugin is implemented as an ECom plug-in object derived from
1.53 +the CContentHandlerBase interface.
1.54 +
1.55 +Each Content Handler plug-in should specify the media type that it handles. Content Handler
1.56 +plug-ins can handle multiple media types: for example, a plug-in to handle SI messages can
1.57 +specify it's media type as "text/vnd.wap.si||application/vnd.wap.sic".
1.58 +
1.59 +@publishedPartner
1.60 +@released
1.61 +*/
1.62 +class CContentHandlerBase : public CPushHandlerBase
1.63 + {
1.64 +public:
1.65 +
1.66 + inline static CContentHandlerBase* NewL(const TDesC& aMatchData);
1.67 +
1.68 + inline virtual ~CContentHandlerBase();
1.69 +
1.70 + inline void SetParent(TMsvId aParentID);
1.71 +
1.72 +protected: // Methods
1.73 +
1.74 + inline CContentHandlerBase();
1.75 +
1.76 + inline void Complete(TInt aError);
1.77 +
1.78 + inline void IdleComplete();
1.79 +
1.80 +protected:
1.81 +
1.82 + /** Parent message server entry. */
1.83 + TMsvId iParentID;
1.84 +
1.85 + /** Unused. */
1.86 + TInt iState; //state machine
1.87 +
1.88 + /** The derived class should set this to ETrue on receiving an asynchronous request. */
1.89 + TBool iAcknowledge;
1.90 +
1.91 + /** Unused. */
1.92 + CPushMessage* iMessage;
1.93 +
1.94 + };
1.95 +
1.96 +#include <push/ccontenthandlerbase.inl>
1.97 +
1.98 +#endif // __CCONTENTHANDLERBASE_H__
1.99 +