1.1 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
1.2 +++ b/epoc32/include/mw/lbttriggerconditionbase.h Tue Mar 16 16:12:26 2010 +0000
1.3 @@ -0,0 +1,119 @@
1.4 +/*
1.5 +* Copyright (c) 2006 Nokia Corporation and/or its subsidiary(-ies).
1.6 +* All rights reserved.
1.7 +* This component and the accompanying materials are made available
1.8 +* 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.9 +* which accompanies this distribution, and is available
1.10 +* at the URL "http://www.symbianfoundation.org/legal/licencesv10.html".
1.11 +*
1.12 +* Initial Contributors:
1.13 +* Nokia Corporation - initial contribution.
1.14 +*
1.15 +* Contributors:
1.16 +*
1.17 +* Description: Abstract base class for trigger condition classes.
1.18 +*
1.19 +*/
1.20 +
1.21 +
1.22 +
1.23 +
1.24 +#ifndef LBTTRIGGERCONDITIONBASE_H
1.25 +#define LBTTRIGGERCONDITIONBASE_H
1.26 +
1.27 +#include <e32base.h>
1.28 +#include <s32strm.h>
1.29 +
1.30 +/**
1.31 + * Abstract base class for trigger condition classes.
1.32 + *
1.33 + * This class is not meant to be derived nor instantiated by client application.
1.34 + * It defines methods that concrete trigger condition class must implement.
1.35 + *
1.36 + * @lib lbt.lib
1.37 + * @since S60 5.1
1.38 + */
1.39 +class CLbtTriggerConditionBase : public CBase
1.40 + {
1.41 +public:
1.42 + /**
1.43 + * Enumeration for trigger condition types.
1.44 + */
1.45 + enum TType
1.46 + {
1.47 + /**
1.48 + * Trigger condition based on geographical area and movement of
1.49 + * the terminal. A trigger is fired when the
1.50 + * terminal enters or leaves the specified trigger area.
1.51 + */
1.52 + ETriggerConditionArea = 1
1.53 + };
1.54 +
1.55 + /**
1.56 + * Destructor
1.57 + */
1.58 + virtual ~CLbtTriggerConditionBase();
1.59 +
1.60 + /**
1.61 + * Gets the type of trigger condition class.
1.62 + * @return The type of trigger condition class.
1.63 + */
1.64 + virtual TType Type() const = 0;
1.65 +
1.66 + /**
1.67 + * Internalizes the trigger condition object's details and attributes
1.68 + * from stream.
1.69 + *
1.70 + * The presence of this function means that the standard templated
1.71 + * operator>>() ( defined in s32strm.h ) is available to internalize objects
1.72 + * of this class.
1.73 + *
1.74 + * @param[in] aStream Stream from which the object should be internalized.
1.75 + */
1.76 + IMPORT_C void InternalizeL( RReadStream& aStream );
1.77 +
1.78 + /**
1.79 + * Externalizes the trigger condition object's details and attributes
1.80 + * to stream.
1.81 + *
1.82 + * The presence of this function means that the standard templated
1.83 + * operator<<() ( defined in s32strm.h ) is available to externalize objects
1.84 + * of this class.
1.85 + *
1.86 + * @param[in] aStream Stream to which the object should be externalized.
1.87 + */
1.88 + IMPORT_C void ExternalizeL( RWriteStream& aStream ) const;
1.89 +
1.90 +protected:
1.91 + /**
1.92 + * Constructor
1.93 + */
1.94 + CLbtTriggerConditionBase();
1.95 +
1.96 + /**
1.97 + * Internalize method that subclass must implement.
1.98 + * @param[in] aStream Stream from which the object should be internalized.
1.99 + */
1.100 + virtual void DoInternalizeL( RReadStream& aStream ) = 0;
1.101 +
1.102 + /**
1.103 + * Externalize method that subclass must implement.
1.104 + * @param[in] aStream Stream to which the object should be externalized.
1.105 + */
1.106 + virtual void DoExternalizeL( RWriteStream& aStream ) const = 0;
1.107 +
1.108 +private:
1.109 + /**
1.110 + * By default, prohibit copy constructor
1.111 + */
1.112 + CLbtTriggerConditionBase( const CLbtTriggerConditionBase& );
1.113 +
1.114 + /**
1.115 + * Prohibit assigment operator
1.116 + */
1.117 + CLbtTriggerConditionBase& operator= ( const CLbtTriggerConditionBase& );
1.118 +
1.119 + };
1.120 +
1.121 +
1.122 +#endif // LBTTRIGGERCONDITIONBASE_H