1 /*************************************************************************
3 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
5 * Copyright 2008 by Sun Microsystems, Inc.
7 * OpenOffice.org - a multi-platform office productivity suite
9 * $RCSfile: XAccessibleRelationSet.idl,v $
12 * This file is part of OpenOffice.org.
14 * OpenOffice.org is free software: you can redistribute it and/or modify
15 * it under the terms of the GNU Lesser General Public License version 3
16 * only, as published by the Free Software Foundation.
18 * OpenOffice.org is distributed in the hope that it will be useful,
19 * but WITHOUT ANY WARRANTY; without even the implied warranty of
20 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
21 * GNU Lesser General Public License version 3 for more details
22 * (a copy is included in the LICENSE file that accompanied this code).
24 * You should have received a copy of the GNU Lesser General Public License
25 * version 3 along with OpenOffice.org. If not, see
26 * <http://www.openoffice.org/license.html>
27 * for a copy of the LGPLv3 License.
29 ************************************************************************/
31 #ifndef __com_sun_star_accessibility_XAccessibleRelationSet_idl__
32 #define __com_sun_star_accessibility_XAccessibleRelationSet_idl__
34 #ifndef __com_sun_star_accessibility_AccessibleRelation_idl__
35 #include
<com
/sun
/star
/accessibility
/AccessibleRelation.idl
>
38 #ifndef __com_sun_star_uno_XInterface_idl__
39 #include
<com
/sun
/star
/uno
/XInterface.idl
>
41 #ifndef __com_sun_star_lang_IndexOutOfBoundsException_idl__
42 #include
<com
/sun
/star
/lang
/IndexOutOfBoundsException.idl
>
45 module com
{ module sun
{ module star
{ module accessibility
{
47 /** Implement this interface to give access to an object's set of relations.
49 <p>Such relation are modeled with the <type>AccessibleRelation</type>
50 structure. This interface is used for representing sets of relations
51 between <type>Accessible</type> objects. Most of the convenience
52 methods of the corresponding AccessibleRelationSet interface of the Java
53 Accessibility API have been removed from this interface in order to
54 clean it up. These methods are <member>add</member>,
55 <member>addAll</member>, <member>clear</member>, and
56 <member>remove</member>. The other methods have been renamed to achieve
57 a geater conformance with the other accessibility interfaces.</p>
61 published
interface XAccessibleRelationSet
: ::com
::sun
::star
::uno
::XInterface
63 /** Returns the number of relations in this relation set.
66 Returns the number of relations or zero if there are none.
68 long getRelationCount
();
70 /** Returns the relation of this relation set that is specified by
74 This index specifies the relatio to return.
77 For a valid index, i.e. inside the range 0 to the number of
78 relations minus one, the returned value is the requested
79 relation. If the index is invalid then the returned relation
83 AccessibleRelation getRelation
([in] long nIndex
)
84 raises
(::com
::sun
::star
::lang
::IndexOutOfBoundsException
);
86 /** Tests whether the relation set contains a relation matching the
90 The type of relation to look for in this set of relations. This
91 has to be one of the constants of
92 <type>AccessibleRelationType</type>.
95 Returns <TRUE/> if there is a (at least one) relation of the
96 given type and <FALSE/> if there is no such relation in the set.
98 boolean containsRelation
([in] short aRelationType
);
100 /** Retrieve and return the relation with the given relation type.
103 The type of the relation to return. This has to be one of the
104 constants of <type>AccessibleRelationType</type>.
107 If a relation with the given type could be found than (a copy
108 of) this relation is returned. Otherwise a relation with the
109 type INVALID is returned.
111 AccessibleRelation getRelationByType
([in] short aRelationType
);