1 // Copyright (c) 1997-2009 Nokia Corporation and/or its subsidiary(-ies).
2 // All rights reserved.
3 // This component and the accompanying materials are made available
4 // under the terms of "Eclipse Public License v1.0"
5 // which accompanies this distribution, and is available
6 // at the URL "http://www.eclipse.org/legal/epl-v10.html".
8 // Initial Contributors:
9 // Nokia Corporation - initial contribution.
14 // This file contains the definition of the CImplementationInformation API class.
24 #ifndef __IMPLEMENTATIONINFORMATION_H__
25 #define __IMPLEMENTATIONINFORMATION_H__
27 // ____________________________________________________________________________
34 // ____________________________________________________________________________
38 Simplifies the definition of extended interfaces array
42 // To be used internally by ECOM and by Phone Manufacturers
43 typedef RArray<TUid> RExtendedInterfacesArray;
47 // ____________________________________________________________________________
51 The CimplementationInformation class acts as the container for the registration
52 data relating to a particular interface implementation.
53 Note that this class is used in both the ECOM client and server side hence the
54 mixed API classification seen below. For the client side only the API used to
55 extract the registration data should be used.
57 NONSHARABLE_CLASS(CImplementationInformation) : public CBase
59 public: // internalComponent APIs
60 // Internal methods used only inside ECOM , not for client use.
62 static CImplementationInformation* NewLC(TBool aClientSide,
63 RReadStream& aStream);
65 static CImplementationInformation* NewL(TUid aUid,
73 static CImplementationInformation* NewL(TUid aUid,
81 RExtendedInterfacesArray* aExtendedInterfaces);
83 ~CImplementationInformation();
85 public: // publishedAll APIs
86 // Available for use by all clients
88 inline const TDesC& DisplayName() const;
90 inline const TDesC8& DataType() const;
91 inline const TDesC8& OpaqueData() const;
93 inline TUid ImplementationUid() const;
94 inline TInt Version() const;
96 inline TDriveUnit Drive() const;
98 inline TBool RomOnly() const;
99 inline TBool RomBased() const;
101 inline TVendorId VendorId() const;
103 inline TBool Disabled() const;
105 // This function should not be used by any ECOM client as it will have no
106 // effect at all on the implementation information stored in the server side
107 inline void SetDisabled(TBool aDisabled);
109 IMPORT_C void GetExtendedInterfaceListL(RExtendedInterfacesArray& aList);
111 public: // internalComponent APIs
112 // Internal methods used inside ECOM, not for client use.
114 void ExternalizeL(TBool aClientSide,RWriteStream& aStream) const;
115 void InternalizeL(TBool aClientSide,RReadStream& aStream);
117 void SetRomBased(TBool aRomBased);
118 void SetDrive(TDriveUnit aDrive);
120 inline void SetVendorId(const TVendorId aVid);
122 void AddExtendedInterfaceL(const TUid& aExtendedInterface);
123 RExtendedInterfacesArray* GetExtendedInterfaceList();
125 private: // internalComponent APIs
126 // Internal methods used inside ECOM, not for client use.
128 CImplementationInformation();
130 CImplementationInformation(TUid aUid,
139 CImplementationInformation(TUid aUid,
147 RExtendedInterfacesArray* aExtendedInterfaces);
150 /** The implementation UID */
151 TUid iImplementationUid;
153 /** The implementation version */
156 /** This implementations human readable name intended for display in
157 UI implementations */
160 /** The type of data this implementation is registered to handle :
161 Used for matching against the run-time cue provided by the client
162 during default interface implementation resolution.
166 /** Data registered for this implementation which can be used by the client
167 during non-default resolution operations but is ignored by the framework.
171 /** The flag recording if this implementation is disabled or enabled */
174 /** The drive that this plug-in resides on */
177 /** The flag recording whether this implementation may only be loaded
178 from read-only internal media */
181 /** This flag records whether this implementation was discovered on
182 read-only internal media or that it is a later version of one that was */
185 /** The Vendor ID of the plug-in which this implementation belongs to*/
188 /** Array of extended interfaces.*/
189 RExtendedInterfacesArray* iExtendedInterfaceList;
191 }; // End CImplementationInformation
194 // ____________________________________________________________________________
198 Simplifies the definition of functions which return registry information
200 typedef RArray<CImplementationInformation*> RImplInfoArray;
203 Simplifies the definition of functions which return registry information
205 typedef RPointerArray<CImplementationInformation> RImplInfoPtrArray;
208 // ____________________________________________________________________________
211 #include <ecom/implementationinformation.inl>
214 #endif // __IMPLEMENTATIONINFORMATION_H__