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_beans_XFastPropertyState_idl__
24#define __com_sun_star_beans_XFastPropertyState_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_beans_PropertyState_idl__
31#include <com/sun/star/beans/PropertyState.idl>
32#endif
33
34#ifndef __com_sun_star_beans_UnknownPropertyException_idl__
35#include <com/sun/star/beans/UnknownPropertyException.idl>
36#endif
37
38#ifndef __com_sun_star_lang_WrappedTargetException_idl__
39#include <com/sun/star/lang/WrappedTargetException.idl>
40#endif
41
42
43//=============================================================================
44
45module com {  module sun {  module star {  module beans {
46
47//=============================================================================
48
49/** makes it possible to query information about the state of
50	one or more properties.
51
52	<p>The state contains the information if:</p>
53	<ul>
54		<li>a value is available or void</li>
55		<li>the value is stored in the object itself, or if a default value is to be used</li>
56		<li>and if the value cannot be determined, due to ambiguity
57			(multi selection with multiple values).</li>
58	</ul>
59 */
60interface XFastPropertyState: ::com::sun::star::uno::XInterface
61{
62	//-------------------------------------------------------------------------
63
64	/** @returns
65				the state of the property.
66
67		@param	aPropertyName
68			specifies the name of the property.
69
70		@throws UnknownPropertyException
71			if the property does not exist.
72	 */
73	::com::sun::star::beans::PropertyState getFastPropertyState( [in] long nHandle )
74			raises( ::com::sun::star::beans::UnknownPropertyException );
75
76	//-------------------------------------------------------------------------
77
78	/** @returns
79			a sequence of the states of the properties which are specified
80				by their names.
81
82		<p>The order of the states is correlating to the order of the
83		given property names. </p>
84
85		@param aPropertyNames
86			contains the sequence of property names.
87
88		@throws UnknownPropertyException
89			if one property does not exist.
90	 */
91	sequence< ::com::sun::star::beans::PropertyState > getFastPropertyStates(
92			[in] sequence< long > aHandles )
93		raises( ::com::sun::star::beans::UnknownPropertyException );
94
95	//-------------------------------------------------------------------------
96
97	/** Sets the property to default value.
98
99		<p>The value depends on the implementation of this interface.
100		If it is a bound property, you must change the value before
101		the change events are fired.  If it is a constrained property, you
102		must fire the vetoable event before you change the property value.
103		</p>
104
105		@param aPropertyname
106			specifies the name of the property.
107
108		@throws UnknownPropertyException
109			if the property does not exist.
110	 */
111	void setFastPropertyToDefault( [in] long nHandle )
112			raises( ::com::sun::star::beans::UnknownPropertyException );
113
114	//-------------------------------------------------------------------------
115
116	/** @returns
117			the default value of the property with the name PropertyName.
118
119		<p>If no default exists, is not known or is void,
120		then the return type is <type>void</type>.
121
122		@param aPropertyName
123			specifies the name of the property.
124
125		@throws UnknownPropertyException
126			if the property does not exist.
127
128		@throws  ::com::sun::star::lang::WrappedTargetException
129			if the implementation has an internal reason for the exception.
130			In this case the original exception is wrapped into that
131			<type scope="::com::sun::star::lang">WrappedTargetException</type>.
132	 */
133	any getFastPropertyDefault( [in] long nHandle )
134			raises( ::com::sun::star::beans::UnknownPropertyException,
135					::com::sun::star::lang::WrappedTargetException );
136};
137
138//=============================================================================
139
140}; }; }; };
141
142#endif
143