1*cdf0e10cSrcweir/*************************************************************************
2*cdf0e10cSrcweir *
3*cdf0e10cSrcweir * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
4*cdf0e10cSrcweir *
5*cdf0e10cSrcweir * Copyright 2000, 2010 Oracle and/or its affiliates.
6*cdf0e10cSrcweir *
7*cdf0e10cSrcweir * OpenOffice.org - a multi-platform office productivity suite
8*cdf0e10cSrcweir *
9*cdf0e10cSrcweir * This file is part of OpenOffice.org.
10*cdf0e10cSrcweir *
11*cdf0e10cSrcweir * OpenOffice.org is free software: you can redistribute it and/or modify
12*cdf0e10cSrcweir * it under the terms of the GNU Lesser General Public License version 3
13*cdf0e10cSrcweir * only, as published by the Free Software Foundation.
14*cdf0e10cSrcweir *
15*cdf0e10cSrcweir * OpenOffice.org is distributed in the hope that it will be useful,
16*cdf0e10cSrcweir * but WITHOUT ANY WARRANTY; without even the implied warranty of
17*cdf0e10cSrcweir * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
18*cdf0e10cSrcweir * GNU Lesser General Public License version 3 for more details
19*cdf0e10cSrcweir * (a copy is included in the LICENSE file that accompanied this code).
20*cdf0e10cSrcweir *
21*cdf0e10cSrcweir * You should have received a copy of the GNU Lesser General Public License
22*cdf0e10cSrcweir * version 3 along with OpenOffice.org.  If not, see
23*cdf0e10cSrcweir * <http://www.openoffice.org/license.html>
24*cdf0e10cSrcweir * for a copy of the LGPLv3 License.
25*cdf0e10cSrcweir *
26*cdf0e10cSrcweir ************************************************************************/
27*cdf0e10cSrcweir#ifndef __com_sun_star_script_XInvocation_idl__
28*cdf0e10cSrcweir#define __com_sun_star_script_XInvocation_idl__
29*cdf0e10cSrcweir
30*cdf0e10cSrcweir#ifndef __com_sun_star_uno_XInterface_idl__
31*cdf0e10cSrcweir#include <com/sun/star/uno/XInterface.idl>
32*cdf0e10cSrcweir#endif
33*cdf0e10cSrcweir
34*cdf0e10cSrcweir#ifndef __com_sun_star_beans_XIntrospectionAccess_idl__
35*cdf0e10cSrcweir#include <com/sun/star/beans/XIntrospectionAccess.idl>
36*cdf0e10cSrcweir#endif
37*cdf0e10cSrcweir
38*cdf0e10cSrcweir#ifndef __com_sun_star_lang_IllegalArgumentException_idl__
39*cdf0e10cSrcweir#include <com/sun/star/lang/IllegalArgumentException.idl>
40*cdf0e10cSrcweir#endif
41*cdf0e10cSrcweir
42*cdf0e10cSrcweir#ifndef __com_sun_star_script_CannotConvertException_idl__
43*cdf0e10cSrcweir#include <com/sun/star/script/CannotConvertException.idl>
44*cdf0e10cSrcweir#endif
45*cdf0e10cSrcweir
46*cdf0e10cSrcweir#ifndef __com_sun_star_reflection_InvocationTargetException_idl__
47*cdf0e10cSrcweir#include <com/sun/star/reflection/InvocationTargetException.idl>
48*cdf0e10cSrcweir#endif
49*cdf0e10cSrcweir
50*cdf0e10cSrcweir#ifndef __com_sun_star_beans_UnknownPropertyException_idl__
51*cdf0e10cSrcweir#include <com/sun/star/beans/UnknownPropertyException.idl>
52*cdf0e10cSrcweir#endif
53*cdf0e10cSrcweir
54*cdf0e10cSrcweir
55*cdf0e10cSrcweir//=============================================================================
56*cdf0e10cSrcweir
57*cdf0e10cSrcweir module com {  module sun {  module star {  module script {
58*cdf0e10cSrcweir
59*cdf0e10cSrcweir//=============================================================================
60*cdf0e10cSrcweir/** gives access to an object's methods and properties.
61*cdf0e10cSrcweir	Container access is available through
62*cdf0e10cSrcweir	<type scope="com::sun::star::container">XIndexContainer</type>,
63*cdf0e10cSrcweir	<type scope="com::sun::star::container">XNameContainer</type> and
64*cdf0e10cSrcweir	<type scope="com::sun::star::container">XEnumerationAccess</type>.
65*cdf0e10cSrcweir	</p>
66*cdf0e10cSrcweir */
67*cdf0e10cSrcweirpublished interface XInvocation: com::sun::star::uno::XInterface
68*cdf0e10cSrcweir{
69*cdf0e10cSrcweir	//-------------------------------------------------------------------------
70*cdf0e10cSrcweir	/** returns the introspection from this object or <NULL/>
71*cdf0e10cSrcweir		if the object does not provide this information.
72*cdf0e10cSrcweir	 */
73*cdf0e10cSrcweir	com::sun::star::beans::XIntrospectionAccess getIntrospection();
74*cdf0e10cSrcweir
75*cdf0e10cSrcweir	//-------------------------------------------------------------------------
76*cdf0e10cSrcweir	/** provides access to methods exposed by an object.
77*cdf0e10cSrcweir
78*cdf0e10cSrcweir		@param aParams all parameters; pure out params are undefined in sequence,
79*cdf0e10cSrcweir					   the value has to be ignored by the callee
80*cdf0e10cSrcweir		@param aOutParamIndex This sequence contains the indices of all parameters
81*cdf0e10cSrcweir						that are specified as out or inout.
82*cdf0e10cSrcweir		@param aOutParam This sequence contains the values of all parameters that
83*cdf0e10cSrcweir						are specified as out or inout and corresponds with the
84*cdf0e10cSrcweir						indices provided by the aOutParamIndex sequence.
85*cdf0e10cSrcweir
86*cdf0e10cSrcweir						Example: aOutParamIndex == { 1, 4 } means that
87*cdf0e10cSrcweir						aOutParam[0] contains the out value of the aParams[1]
88*cdf0e10cSrcweir						parameter and aOutParam[1] contains the out value of
89*cdf0e10cSrcweir						the aParams[4] parameter.
90*cdf0e10cSrcweir	 */
91*cdf0e10cSrcweir	any invoke( [in] string aFunctionName,
92*cdf0e10cSrcweir			 [in] sequence<any> aParams,
93*cdf0e10cSrcweir			 [out] sequence<short> aOutParamIndex,
94*cdf0e10cSrcweir			 [out] sequence<any> aOutParam )
95*cdf0e10cSrcweir			raises( com::sun::star::lang::IllegalArgumentException,
96*cdf0e10cSrcweir					com::sun::star::script::CannotConvertException,
97*cdf0e10cSrcweir					com::sun::star::reflection::InvocationTargetException );
98*cdf0e10cSrcweir
99*cdf0e10cSrcweir	//-------------------------------------------------------------------------
100*cdf0e10cSrcweir	/** sets a value to the property with the specified name.
101*cdf0e10cSrcweir
102*cdf0e10cSrcweir		<p> If the underlying object implements an
103*cdf0e10cSrcweir		<type scope="com::sun::star::container">XNameContainer</type>,
104*cdf0e10cSrcweir		then this method will insert the value if there is no such
105*cdf0e10cSrcweir		<var>aPropertyName</var>.
106*cdf0e10cSrcweir
107*cdf0e10cSrcweir		</p>
108*cdf0e10cSrcweir	 */
109*cdf0e10cSrcweir	void setValue( [in] string aPropertyName,
110*cdf0e10cSrcweir			 [in] any aValue )
111*cdf0e10cSrcweir			raises( com::sun::star::beans::UnknownPropertyException,
112*cdf0e10cSrcweir					com::sun::star::script::CannotConvertException,
113*cdf0e10cSrcweir					com::sun::star::reflection::InvocationTargetException );
114*cdf0e10cSrcweir
115*cdf0e10cSrcweir	//-------------------------------------------------------------------------
116*cdf0e10cSrcweir	/** returns the value of the property with the specified name.
117*cdf0e10cSrcweir
118*cdf0e10cSrcweir		@param aPropertyName
119*cdf0e10cSrcweir			specifies the name of the property.
120*cdf0e10cSrcweir	 */
121*cdf0e10cSrcweir	any getValue( [in] string aPropertyName )
122*cdf0e10cSrcweir			raises( com::sun::star::beans::UnknownPropertyException );
123*cdf0e10cSrcweir
124*cdf0e10cSrcweir	//-------------------------------------------------------------------------
125*cdf0e10cSrcweir	/** returns <TRUE/> if the method with the specified name exists, else <FALSE/>.
126*cdf0e10cSrcweir
127*cdf0e10cSrcweir		<p>This optimizes the calling sequence
128*cdf0e10cSrcweir		( <member>XInvocation::hasMethod</member>,
129*cdf0e10cSrcweir		<member>XInvocation::invoke</member> )!</p>
130*cdf0e10cSrcweir
131*cdf0e10cSrcweir				@param aName
132*cdf0e10cSrcweir					specifies the name of the method.
133*cdf0e10cSrcweir	 */
134*cdf0e10cSrcweir	boolean hasMethod( [in] string aName );
135*cdf0e10cSrcweir
136*cdf0e10cSrcweir	//-------------------------------------------------------------------------
137*cdf0e10cSrcweir	/** returns <TRUE/> if the property with the specified name exists, else <FALSE/>.
138*cdf0e10cSrcweir
139*cdf0e10cSrcweir				<p>This optimizes the calling sequence
140*cdf0e10cSrcweir				( <member>XInvocation::hasProperty</member>,
141*cdf0e10cSrcweir				<member>XInvocation::getValue</member> ) or
142*cdf0e10cSrcweir
143*cdf0e10cSrcweir				( <member>XInvocation::hasProperty</member>,
144*cdf0e10cSrcweir				<member>XInvocation::setValue</member> )!
145*cdf0e10cSrcweir
146*cdf0e10cSrcweir					@param aName
147*cdf0e10cSrcweir				specifies the name of the property.
148*cdf0e10cSrcweir	 */
149*cdf0e10cSrcweir	boolean hasProperty( [in] string aName );
150*cdf0e10cSrcweir
151*cdf0e10cSrcweir};
152*cdf0e10cSrcweir
153*cdf0e10cSrcweir//=============================================================================
154*cdf0e10cSrcweir
155*cdf0e10cSrcweir}; }; }; };
156*cdf0e10cSrcweir
157*cdf0e10cSrcweir#endif
158