fix baseline build (old cairo) - 'cairo_rectangle_int_t' does not name a type
[LibreOffice.git] / udkapi / com / sun / star / lang / XConnectionPoint.idl
blob2177207b14d9b34b230531d0628539822c1f3fb2
1 /* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
2 /*
3 * This file is part of the LibreOffice project.
5 * This Source Code Form is subject to the terms of the Mozilla Public
6 * License, v. 2.0. If a copy of the MPL was not distributed with this
7 * file, You can obtain one at http://mozilla.org/MPL/2.0/.
9 * This file incorporates work covered by the following license notice:
11 * Licensed to the Apache Software Foundation (ASF) under one or more
12 * contributor license agreements. See the NOTICE file distributed
13 * with this work for additional information regarding copyright
14 * ownership. The ASF licenses this file to you under the Apache
15 * License, Version 2.0 (the "License"); you may not use this file
16 * except in compliance with the License. You may obtain a copy of
17 * the License at http://www.apache.org/licenses/LICENSE-2.0 .
19 #ifndef __com_sun_star_lang_XConnectionPoint_idl__
20 #define __com_sun_star_lang_XConnectionPoint_idl__
22 #include <com/sun/star/uno/XInterface.idl>
23 #include <com/sun/star/lang/XConnectionPointContainer.idl>
25 #include <com/sun/star/lang/ListenerExistException.idl>
27 #include <com/sun/star/lang/InvalidListenerException.idl>
31 module com { module sun { module star { module lang {
33 /** supports connection points for connectable objects.
35 <p>Connectable objects support the following features: </p>
37 <ul>
38 <li>outgoing interfaces, such as event sets; </li>
39 <li>the ability to enumerate the types of the outgoing interfaces;
40 <li>the ability to connect and disconnect sinks to the object
41 for those outgoing types; </li>
42 <li>the ability to enumerate the connections that exist to a
43 particular outgoing interface. </li>
44 </ul>
46 <h4>When to Implement?</h4>
48 <p>To create a connectable object, you need to implement objects
49 that provide two related interfaces: </p>
51 <ul>
52 <li>XConnectionPointContainer </li>
53 <li>XConnectionPoint </li>
54 </ul>
56 <p>The XConnectionPointContainer interface is implemented
57 on the connectable object to indicate the existence of the outgoing
58 interfaces. It provides a sequence of sub-objects. It also provides
59 access to all the connection point sub-objects, each of which
60 implements the XConnectionPoint interface. The
61 XConnectionPoint interface provides a sequence of
62 sub-objects. </p>
64 <p>Each connection point is a separate sub-object to avoid circular
65 reference counting problems. A connection point controls how many
66 connections (one or more) it will allow in its implementation of
67 XConnectionPoint::advise(). </p>
69 <h4>When to use?</h4>
71 <p>A client can use the XConnectionPointContainer interface: </p>
73 - to get a sequence of connection points for each outgoing type.
75 - to obtain access to connection point sub-objects with the
76 XConnectionPoint interface for each
77 outgoing type. Through the XConnectionPoint interface,
78 a client starts or terminates an advisory loop with the
79 connectable object and the client's own sink. The
80 client can also use the XConnectionPoint
81 interface to get a sequence of the connections that it
82 knows about.
84 @see XConnectionPointContainer
86 published interface XConnectionPoint: com::sun::star::uno::XInterface
88 /** @returns
89 the type of the outgoing interface managed by this
90 connection point.
92 <p>Using the XConnectionPointContainer::getConnectionPoints()
93 method, a client can obtain an XConnectionPoint
94 interface. Using that interface and this method, the client
95 can determine the type of each connection point enumerated. The
96 type returned from this method must enable the caller to access
97 this same connection point through
98 XConnectionPointContainer::findConnectionPoint().
100 @see XConnectionPointContainer::findConnectionPoint
102 type getConnectionType();
104 /** @returns
105 the XConnectionPointContainer interface on
106 the parent connectable object.
108 @see XConnectionPointContainer
110 com::sun::star::lang::XConnectionPointContainer getConnectionPointContainer();
112 /** creates a connection between a connection point and a
113 client's sink, where the sink implements the outgoing interface
114 supported by this connection point.
116 <p>A few <code>add...Listener</code> methods need additional parameters
117 to add listeners or throw exceptions. One of these methods is
118 com::sun::star::beans::XPropertySet::addPropertyChangeListener().
119 We ignore the problem in this interface. A solution must be provided
120 in an additional XConnectionPoint interface. </p>
122 @param xListener
123 specifies the listener interface on the client's advise sink.
124 The client's sink receives outgoing calls from the
125 connection point container.
127 @throws ListenerExistException
128 if it is a unicast broadcaster and a listener is already set.
130 @throws InvalidListenerException
131 if the listener does not supply the needed interfaces.
133 @see com::sun::star::beans::XPropertySet::addPropertyChangeListener
135 void advise( [in] com::sun::star::uno::XInterface xListener )
136 raises( com::sun::star::lang::ListenerExistException,
137 com::sun::star::lang::InvalidListenerException );
139 /** terminates a notification previously set up with advise.
141 <p>A few <code>remove...Listener</code> methods need additional
142 parameters to add listeners or throw exceptions. One of these methods
143 is com::sun::star::beans::XPropertySet::removePropertyChangeListener().
144 We ignore the problem in this interface. A solution must be
145 provided in an additional XConnectionPoint interface. </p>
147 @param xListener
148 specifies the listener interface on the client's advise sink.
150 @see com::sun::star::beans::XPropertySet::removePropertyChangeListener
152 void unadvise( [in] com::sun::star::uno::XInterface xListener );
154 /** @returns
155 a sequence of all currently advised connections.
157 sequence<com::sun::star::uno::XInterface> getConnections();
162 }; }; }; };
164 #endif
166 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */