os/security/contentmgmt/contentaccessfwfordrm/source/f32agent/f32agentfactory.h
author sl@SLION-WIN7.fritz.box
Fri, 15 Jun 2012 03:10:57 +0200
changeset 0 bde4ae8d615e
permissions -rw-r--r--
First public contribution.
     1 /*
     2 * Copyright (c) 2003-2009 Nokia Corporation and/or its subsidiary(-ies).
     3 * All rights reserved.
     4 * This component and the accompanying materials are made available
     5 * under the terms of the License "Eclipse Public License v1.0"
     6 * which accompanies this distribution, and is available
     7 * at the URL "http://www.eclipse.org/legal/epl-v10.html".
     8 *
     9 * Initial Contributors:
    10 * Nokia Corporation - initial contribution.
    11 *
    12 * Contributors:
    13 *
    14 * Description: 
    15 *
    16 */
    17 
    18 
    19 /**
    20  @file
    21  @internalComponent
    22  @released
    23 */
    24 
    25 
    26 #ifndef __F32AGENTFACTORY_H__
    27 #define __F32AGENTFACTORY_H__
    28 
    29 #include <caf/agentfactory.h>
    30 
    31 namespace ContentAccess
    32 	{
    33 	class CAgentContent;
    34 	class CAgentManager;
    35 	class CAgentData;
    36 
    37 	/** 
    38 	 Creates products that allow access to plaintext unprotected files
    39 	 via the Content Access Framework (CAF)
    40 	 
    41 	 The F32 agent is treated as a special case by CAF. It is 
    42 	 the default agent used when no other suitable agent is found
    43 	 for a particular operation.
    44 	 
    45 	 No translation of the content will occur and no access restrictions
    46 	 will be enforced aside from the usual platform security data caging
    47 	 rules.
    48 	 
    49 	 @internalComponent
    50 	 @released
    51 	 */
    52 	class CF32AgentFactory : public CAgentFactory
    53 		{
    54 	public:
    55 		/** Entry point for F32 Agent 
    56 		@return a new F32AgentFactory instance
    57 		*/
    58 		static CAgentFactory* NewL();
    59 		
    60 		// From CAgentFactory
    61 		virtual CAgentContent* CreateContentBrowserL(const TDesC& aURI, TContentShareMode aShareMode);	
    62 		virtual CAgentContent* CreateContentBrowserL(RFile& aFile);
    63 		virtual CAgentData* CreateDataConsumerL(const TVirtualPathPtr& aVirtualPath, TContentShareMode aShareMode);
    64 		virtual CAgentData* CreateDataConsumerL(RFile& aFile, const TDesC& aUniqueId);
    65 		virtual CAgentManager*  CreateManagerL();
    66 
    67 		/** The F32 Agent cannot be used to receive files
    68 		
    69 		The CAF framework should know this is the F32 agent and never
    70 		attempt to call this method
    71 		
    72 		@panic CAF EF32AgentImportNotSupported 
    73 		*/
    74 		virtual CAgentImportFile* CreateImporterL(const TDesC8& aMimeType, const CMetaDataArray& aMetaDataArray, const TDesC& aOutputDirectory, const TDesC& aSuggestedFileName);
    75 		/** The F32 Agent cannot be used to receive files
    76 
    77 		The CAF framework should know this is the F32 agent and never
    78 		attempt to call this method
    79 
    80 		@panic CAF EF32AgentImportNotSupported 
    81 		*/
    82 		virtual CAgentImportFile* CreateImporterL(const TDesC8& aMimeType, const CMetaDataArray& aMetaDataArray);
    83 		/** The F32 Agent does not manage any rights
    84 
    85 		The CAF framework should know this is the F32 agent and never
    86 		attempt to call this method
    87 
    88 		@panic CAF EF32AgentRightsManagerNotSupported 
    89 		*/
    90 		virtual CAgentRightsManager* CreateRightsManagerL();
    91 		
    92 #ifdef SYMBIAN_ENABLE_SDP_WMDRM_SUPPORT
    93 		virtual CAgentData* CreateDataConsumerL(const TDesC8& aHeaderData);
    94 		virtual CAgentContent* CreateContentBrowserL(const TDesC8& aHeaderData);
    95 #endif // SYMBIAN_ENABLE_SDP_WMDRM_SUPPORT		
    96 		};
    97 } // namespace ContentAccess
    98 #endif // __F32AGENTFACTORY_H__