sl@0: // Copyright (c) 2007-2009 Nokia Corporation and/or its subsidiary(-ies). sl@0: // All rights reserved. sl@0: // This component and the accompanying materials are made available sl@0: // under the terms of the License "Eclipse Public License v1.0" sl@0: // which accompanies this distribution, and is available sl@0: // at the URL "http://www.eclipse.org/legal/epl-v10.html". sl@0: // sl@0: // Initial Contributors: sl@0: // Nokia Corporation - initial contribution. sl@0: // sl@0: // Contributors: sl@0: // sl@0: // Description: sl@0: // sl@0: sl@0: /** sl@0: @file sl@0: @internalComponent sl@0: @released sl@0: */ sl@0: sl@0: #ifndef STREAMAGENTINFO_H sl@0: #define STREAMAGENTINFO_H sl@0: sl@0: #include sl@0: sl@0: class CImplementationInformation; sl@0: class CSdpMediaField; sl@0: sl@0: namespace StreamAccess sl@0: { sl@0: sl@0: class CStreamAgentFactory; sl@0: sl@0: /* Stores information regarding a Stream Agent interface plug-in implementation. sl@0: * sl@0: * Registration data from the plug-in's resource file and details about the sl@0: * agents decryption capabilities are contained so that the stream agents credentials sl@0: * can be obtained without the need to instantiate an instantce of it. sl@0: * sl@0: * If an instance of the agent is required, the StreamAgentFactoryL() method provides a sl@0: * handle to it's factory object. sl@0: */ sl@0: class CStreamAgentInfo : public CBase sl@0: { sl@0: public: sl@0: sl@0: /* Constructs a new instance of CStreamAgentInfo and pushs it onto the cleanup stack sl@0: * @param aImplementationInfo Contains regristration information relating to the stream sl@0: * agent interface implementation sl@0: * @return Pointer to the new CStreamAgentInfo object sl@0: */ sl@0: static CStreamAgentInfo* NewLC(const CImplementationInformation& aImplementationInfo); sl@0: sl@0: /* Destructor sl@0: */ sl@0: ~CStreamAgentInfo(); sl@0: sl@0: /* Returns the name of the stream agent plug-in implementation sl@0: * @return Name of the steam agent interface implementation sl@0: */ sl@0: const TDesC& Name() const; sl@0: sl@0: /* Returns the implementation UID of the stream agent plug-in DLL sl@0: * @return Implementation UID of the stream agent plug-in DLL sl@0: */ sl@0: TUid ImplementationUid() const; sl@0: sl@0: /* Determines whether the stream agent is capable of decoding the specified key stream sl@0: * @param aSdpKeyStream Conatins the metadata for SDP key management scheme of the stream sl@0: * @return ETrue if the stream agent recognises the SDP format and is able to sl@0: * decode the key stream sl@0: * @return EFalse if the stream agent fails to recognise the SDP format or is unable to sl@0: * decode the key stream sl@0: */ sl@0: TBool IsKeyStreamSupportedL(const CSdpMediaField& aSdpKeyStream) const; sl@0: sl@0: /* Returns a handle to the stream agents factory. sl@0: * sl@0: * The factory is instantiated once and can then be called many times. This method sl@0: * DOES NOT transfer ownership of the factory to the calling client. sl@0: * sl@0: * @return Reference to the CStreamAgentFactory instance sl@0: */ sl@0: CStreamAgentFactory& StreamAgentFactory() const; sl@0: sl@0: protected: sl@0: sl@0: /* Constructor sl@0: */ sl@0: CStreamAgentInfo(); sl@0: sl@0: /* Second phase of construction for CStreamAgentInfo sl@0: * @param aImplementationInfo Contains registration information relating to the stream sl@0: * agent interface implementation sl@0: */ sl@0: void ConstructL(const CImplementationInformation& aImplementationInfo); sl@0: sl@0: private: sl@0: sl@0: /* Name of the stream agent plug-in implementation sl@0: */ sl@0: HBufC* iName; sl@0: sl@0: /* Implementation UID of the stream agent plug-in DLL sl@0: */ sl@0: TUid iImplementationUid; sl@0: sl@0: /* Stream agent factory handle used to generate instances of the agent key stream decoder sl@0: */ sl@0: CStreamAgentFactory* iStreamAgentFactory; sl@0: sl@0: // ECOM session key. This is set by REComSession::CreateImplementationL() during construction sl@0: TUid iEcomKey; sl@0: }; sl@0: } // namespace StreamAccess sl@0: #endif /*STREAMAGENTINFO_H*/