1/************************************************************************* 2 * 3 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 4 * 5 * Copyright 2000, 2010 Oracle and/or its affiliates. 6 * 7 * OpenOffice.org - a multi-platform office productivity suite 8 * 9 * This file is part of OpenOffice.org. 10 * 11 * OpenOffice.org is free software: you can redistribute it and/or modify 12 * it under the terms of the GNU Lesser General Public License version 3 13 * only, as published by the Free Software Foundation. 14 * 15 * OpenOffice.org is distributed in the hope that it will be useful, 16 * but WITHOUT ANY WARRANTY; without even the implied warranty of 17 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 18 * GNU Lesser General Public License version 3 for more details 19 * (a copy is included in the LICENSE file that accompanied this code). 20 * 21 * You should have received a copy of the GNU Lesser General Public License 22 * version 3 along with OpenOffice.org. If not, see 23 * <http://www.openoffice.org/license.html> 24 * for a copy of the LGPLv3 License. 25 * 26 ************************************************************************/ 27 28#ifndef __com_sun_star_drawing_framework_XResourceFactoryManager_idl__ 29#define __com_sun_star_drawing_framework_XResourceFactoryManager_idl__ 30 31#ifndef __com_sun_star_uno_XInterface_idl__ 32#include <com/sun/star/uno/XInterface.idl> 33#endif 34 35module com { module sun { module star { module drawing { module framework { 36 37published interface XResourceId; 38published interface XResourceFactory; 39 40/** The XResourceFactoryManager is part of the configuration controller and 41 manages the set of registered resource factories. 42 43 @see XConfigurationController 44 @see XResourceFactory 45*/ 46published interface XResourceFactoryManager 47{ 48 /** Register a new resource factory for the given URL. 49 <p>When one factory is responsible for more than one type of resource 50 then this method has to be called for each type. If this method is 51 called multiple times for the same URL then a previously registered 52 factory is removed for the URL.</p> 53 @param sResourceURL 54 The URL of the resource that the factory can create. 55 @param xResourceFactory 56 The resource factory object. 57 */ 58 void addResourceFactory ( 59 [in] string sResourceURL, 60 [in] XResourceFactory xResourceFactory); 61 62 /** Remove a resource factory for one type of resource. When the 63 factory has been registered for other URLs as well then it remains 64 registered for them. Use the 65 <member>removeResourceFactoryForReference()</member> to remove a 66 factory completely. 67 @param sResourceURL 68 The URL for which to remove the resource factory. 69 */ 70 void removeResourceFactoryForURL ( 71 [in] string sResourceURL); 72 73 /** Remove a resource factory for all resource types it has been registered for. Use 74 <member>removeResourceFactoryForURL</member> to remove a factory 75 just for one resource type and to leave it registered for others. 76 @param xResourceFactory 77 The resource factory object to remove. 78 */ 79 void removeResourceFactoryForReference ( 80 [in] XResourceFactory xResourceFactory); 81 82 /** Return the resource factory that was previously registered for the 83 given resource type. This method is typically called by one of the 84 resource controllers. 85 @param sResourceURL 86 The URL of the resource type for which to return the resource 87 factory. 88 @return 89 When no resource factory was registered for the given resource 90 type then an empty reference is returned. 91 */ 92 XResourceFactory getResourceFactory ( 93 [in] string sResourceURL); 94}; 95 96}; }; }; }; }; // ::com::sun::star::drawing::framework 97 98#endif 99