1/**************************************************************
2 *
3 * Licensed to the Apache Software Foundation (ASF) under one
4 * or more contributor license agreements.  See the NOTICE file
5 * distributed with this work for additional information
6 * regarding copyright ownership.  The ASF licenses this file
7 * to you under the Apache License, Version 2.0 (the
8 * "License"); you may not use this file except in compliance
9 * with the License.  You may obtain a copy of the License at
10 *
11 *   http://www.apache.org/licenses/LICENSE-2.0
12 *
13 * Unless required by applicable law or agreed to in writing,
14 * software distributed under the License is distributed on an
15 * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
16 * KIND, either express or implied.  See the License for the
17 * specific language governing permissions and limitations
18 * under the License.
19 *
20 *************************************************************/
21
22
23#ifndef __com_sun_star_embed_XLinkCreator_idl__
24#define __com_sun_star_embed_XLinkCreator_idl__
25
26#ifndef __com_sun_star_uno_XInterface_idl__
27#include <com/sun/star/uno/XInterface.idl>
28#endif
29
30#ifndef __com_sun_star_embed_XStorage_idl__
31#include <com/sun/star/embed/XStorage.idl>
32#endif
33
34#ifndef __com_sun_star_io_IOException_idl__
35#include <com/sun/star/io/IOException.idl>
36#endif
37
38#ifndef __com_sun_star_embed_WrongStateException_idl__
39#include <com/sun/star/embed/WrongStateException.idl>
40#endif
41
42#ifndef __com_sun_star_lang_IllegalArgumentException_idl__
43#include <com/sun/star/lang/IllegalArgumentException.idl>
44#endif
45
46#ifndef __com_sun_star_beans_PropertyValue_idl__
47#include <com/sun/star/beans/PropertyValue.idl>
48#endif
49
50//=============================================================================
51
52 module com {  module sun {  module star {  module embed {
53
54//=============================================================================
55/** allows to create and initialize a new link.
56	<p>
57	Methods of this interface does not require specification of the object type,
58	it will be detected.
59	</p>
60 */
61published interface XLinkCreator: com::sun::star::uno::XInterface
62{
63	//-------------------------------------------------------------------------
64    /** creates a new object based on
65		<type scope="com::sun::star::document">MediaDescriptor</type>
66		and initializes it as a link.
67
68		<p>
69		In case the entry exists already all it's contents will be ignored and
70		rewritten on storing of the object.
71		</p>
72
73		@param xStorage
74			a parent storage the entry should be created/opened in
75
76		@param sEntryName
77			a name for the entry
78
79		@param aArgs
80			<type scope="com::sun::star::document">MediaDescriptor</type>
81			the link will be based on
82
83        @param aObjectArgs
84            optional parameters for the object persistence initialization,
85            see also
86			<type scope="com::sun::star::embed">EmbeddedObjectDescriptor</type>
87
88		@throws ::com::sun::star::lang::IllegalArgumentException
89			the argument is illegal
90
91        @throws com::sun::star::io::IOException
92			in case of io problems during opening\creation
93
94        @throws com::sun::star::uno::Exception
95			in case of other problems
96	 */
97	::com::sun::star::uno::XInterface createInstanceLink(
98			[in] ::com::sun::star::embed::XStorage xStorage,
99		 	[in] string sEntryName,
100		 	[in] sequence< ::com::sun::star::beans::PropertyValue > aArgs,
101			[in] sequence< ::com::sun::star::beans::PropertyValue > aObjectArgs )
102		raises( ::com::sun::star::lang::IllegalArgumentException,
103				::com::sun::star::io::IOException,
104				::com::sun::star::uno::Exception );
105};
106
107//=============================================================================
108
109}; }; }; };
110
111#endif
112
113