1.1 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
1.2 +++ b/epoc32/include/ct/tctfindtokentypesbyinterfaceandattribute.h Tue Mar 16 16:12:26 2010 +0000
1.3 @@ -0,0 +1,78 @@
1.4 +/*
1.5 +* Copyright (c) 2001-2009 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 "Eclipse Public License v1.0"
1.9 +* which accompanies this distribution, and is available
1.10 +* at the URL "http://www.eclipse.org/legal/epl-v10.html".
1.11 +*
1.12 +* Initial Contributors:
1.13 +* Nokia Corporation - initial contribution.
1.14 +*
1.15 +* Contributors:
1.16 +*
1.17 +* Description:
1.18 +*
1.19 +*/
1.20 +
1.21 +
1.22 +
1.23 +
1.24 +/**
1.25 + @file
1.26 + @publishedPartner
1.27 + @released
1.28 +*/
1.29 +
1.30 +#ifndef __TCTFINDTOKENTYPESBYINTERFACEANDATTRIBUTE_H__
1.31 +#define __TCTFINDTOKENTYPESBYINTERFACEANDATTRIBUTE_H__
1.32 +
1.33 +#include <ct/mcttokentypefilter.h>
1.34 +
1.35 +
1.36 +struct TCTTokenTypeAttribute;
1.37 +
1.38 +
1.39 +/**
1.40 + * A filter that returns only those token types that match the required set of
1.41 + * interfaces and attributes.
1.42 + *
1.43 + * On construction, an array containing the required interfaces and an array
1.44 + * of required attributes/values is passed in.
1.45 + *
1.46 + * Token types will be matched if every interface in the supplied array is supported
1.47 + * by the token type, and every attribute is defined and has the same value.
1.48 + *
1.49 + * @since v7.0
1.50 + */
1.51 +class TCTFindTokenTypesByInterfaceAndAttribute : public MCTTokenTypeFilter
1.52 + {
1.53 + public:
1.54 + /**
1.55 + * Constructor.
1.56 + *
1.57 + * @param aInterfaces An array of Uids corresponding to the interfaces that the
1.58 + * token type must support.
1.59 + * @param aAttributes An array of the attributes and values that must be defined
1.60 + * for the token type.
1.61 + */
1.62 + IMPORT_C TCTFindTokenTypesByInterfaceAndAttribute(const TArray<TUid> aInterfaces,
1.63 + const TArray<TCTTokenTypeAttribute> aAttributes);
1.64 +
1.65 + /**
1.66 + * Tests whether all the interfaces and attributes associated with the filter
1.67 + * are supported by the token type.
1.68 + *
1.69 + * @param aTokenType The token type to be tested.
1.70 + * @return ETrue if all the interfaces and attributes associated with the
1.71 + * filter are supported by the token type; EFalse, otherwise.
1.72 + */
1.73 + virtual TBool Accept(const CCTTokenTypeInfo& aTokenType) const;
1.74 +
1.75 + private:
1.76 + const TArray<TUid> iInterfaces;
1.77 + const TArray<TCTTokenTypeAttribute> iAttributes;
1.78 + };
1.79 +
1.80 +
1.81 +#endif // __TCTFINDTOKENTYPESBYINTERFACEANDATTRIBUTE_H__