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#if ! defined INCLUDED_com_sun_star_deployment_XPackageManagerFactory_idl
29#define INCLUDED_com_sun_star_deployment_XPackageManagerFactory_idl
30
31#include <com/sun/star/lang/IllegalArgumentException.idl>
32#include <com/sun/star/deployment/XPackageManager.idl>
33
34
35module com { module sun { module star { module deployment {
36
37/** The <type>XPackageManagerFactory</type> interface is used to obtain
38    <type>XPackageManager</type> instances.
39    <p>
40    You have to use the singleton
41    <code>
42    /singletons/com.sun.star.deployment.thePackageManagerFactory
43    </code>
44    exclusively.
45    </p>
46
47    @since OOo 2.0
48    @deprecated
49    Use <type>XExtensionManager</type>.
50*/
51interface XPackageManagerFactory
52{
53    /** Method to create (or reusing and already existing)
54        <type>XPackageManager</type> object to add or remove UNO packages
55        persistently.
56        <p>
57        Packages for context strings <code>"user"</code> and
58        <code>"shared"</code> will be registered and
59        revoked persistently.
60        </p>
61        <!-- p>
62        Document contexts (<code>"vnd.sun.star.tdoc:..."</code>) will get a
63        <type>XPackageManager</type> object that stores packages
64        in the given document and modify the manifest.
65        </p -->
66        <p>
67        Context strings other than <code>"user"</code>, <code>"shared"</code>
68        <!-- or <code>vnd.sun.star.tdoc</code --> will last in an
69        <type scope="com::sun::star::lang">IllegalArgumentException</type>.
70        </p>
71
72        @param context
73               context string, e.g.
74               <ul>
75               <li><code>"user"</code>
76                   => persistent storage and registration into installation's
77                      user layer
78               </li>
79               <li><code>"shared"</code>
80                   => persistent storage and registration into installation's
81                      shared layer
82               </li>
83               <!-- li><code>"vnd.sun.star.tdoc:///4711/uno_packages"</code>
84                        (open document)
85                   => transient storage in folder uno_packages
86                      and transient registration
87               </li -->
88               </ul>
89        @return
90               <type>XPackageManager</type> object
91        @throws ::com::sun::star::lang::IllegalArgumentException
92                in case of an invalid context
93    */
94    XPackageManager getPackageManager( [in] string context )
95        raises (com::sun::star::lang::IllegalArgumentException);
96};
97
98}; }; }; };
99
100#endif
101