Update ooo320-m1
[ooovba.git] / offapi / com / sun / star / form / control / GridControl.idl
blob2ea4234a93a1f8e000c54b7900370b8c5b5dd514
1 /*************************************************************************
3 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
4 *
5 * Copyright 2008 by Sun Microsystems, Inc.
7 * OpenOffice.org - a multi-platform office productivity suite
9 * $RCSfile: GridControl.idl,v $
10 * $Revision: 1.11 $
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_form_control_GridControl_idl__
32 #define __com_sun_star_form_control_GridControl_idl__
34 #ifndef __com_sun_star_awt_UnoControl_idl__
35 #include <com/sun/star/awt/UnoControl.idl>
36 #endif
38 #ifndef __com_sun_star_form_XGrid_idl__
39 #include <com/sun/star/form/XGrid.idl>
40 #endif
42 #ifndef __com_sun_star_form_XBoundComponent_idl__
43 #include <com/sun/star/form/XBoundComponent.idl>
44 #endif
46 #ifndef __com_sun_star_form_XGridFieldDataSupplier_idl__
47 #include <com/sun/star/form/XGridFieldDataSupplier.idl>
48 #endif
50 #ifndef __com_sun_star_util_XModifyBroadcaster_idl__
51 #include <com/sun/star/util/XModifyBroadcaster.idl>
52 #endif
54 #ifndef __com_sun_star_util_XModeSelector_idl__
55 #include <com/sun/star/util/XModeSelector.idl>
56 #endif
58 #ifndef __com_sun_star_container_XIndexAccess_idl__
59 #include <com/sun/star/container/XIndexAccess.idl>
60 #endif
62 #ifndef __com_sun_star_container_XEnumerationAccess_idl__
63 #include <com/sun/star/container/XEnumerationAccess.idl>
64 #endif
66 #ifndef __com_sun_star_container_XContainer_idl__
67 #include <com/sun/star/container/XContainer.idl>
68 #endif
70 #ifndef __com_sun_star_frame_XDispatchProviderInterception_idl__
71 #include <com/sun/star/frame/XDispatchProviderInterception.idl>
72 #endif
74 #ifndef __com_sun_star_view_XSelectionSupplier_idl__
75 #include <com/sun/star/view/XSelectionSupplier.idl>
76 #endif
78 //=============================================================================
80 module com { module sun { module star { module form {
82 published interface XGridControl;
84 module control {
86 //=============================================================================
88 /** describes a table-like control for displaying data.
90 <p>The model of the control has to support the <type scope="com::sun::star::form::component">GridControl</type>
91 service.</p>
93 @see com::sun::star::awt::UnoControl
94 @see com::sun::star::awt::UnoControlModel
96 published service GridControl
98 service com::sun::star::awt::UnoControl;
100 /** allows committing the content of the active cell of the control.
102 interface com::sun::star::form::XBoundComponent;
104 /** allows access to the active cell within the grid.
106 <p>Only the column position can be modified using this interface, as the row position within
107 a table control bound to a data source is given implicitly (by the cursor position of the data source).</p>
109 interface com::sun::star::form::XGrid;
111 [optional] interface com::sun::star::form::XGridControl;
113 /** used to broadcast modifications made by the user (within the active cell)
115 interface com::sun::star::util::XModifyBroadcaster;
117 /** allows access to the field data of the grid's current row in different formats
119 [optional] interface com::sun::star::form::XGridFieldDataSupplier;
121 /** allows access to objects wrapping a single column
123 interface com::sun::star::container::XIndexAccess;
125 /** allows creation of an enumeration for the column objects
127 interface com::sun::star::container::XEnumerationAccess;
129 /** is used to switch the operating modes of the control.
131 <p>Besides the normal opreration mode (which is used to display the database form's data) the control may
132 for instance support a filter mode.</p>
134 [optional] interface com::sun::star::util::XModeSelector;
136 /** used to control the selection of rows in the grid control.
138 <p>The selection used with the methods <method scope="com::sun::star::view">XSelectionSupplier::getSelection</method>
139 and <method scope="com::sun::star::view">XSelectionSupplier::select</method> is a sequence of Any's.<br/>
140 Here the elements of the Sequence are the bookmarks (in the <type scope="com::sun::star::sdb">RowSet</type>)
141 of the (to-be-) selected rows.</p>
143 [optional] interface com::sun::star::view::XSelectionSupplier;
145 /** allows external components to register dispatchers for some common form actions.
147 <p>A grid control can contain own UI elements for traveling within the database form it belongs to (This
148 concept seems to make sense, as a grid control - in opposite to other data aware controls - displayes
149 not only one record at a time, but a larger number of records of the database form.)<br/>
150 With the help of this interface, external components which wish to handle such travelings themself can
151 register interceptors for the actions in question.</p>
153 <p>Usual URLs to use include
154 <dl>
155 <dt>.uno:FormSlots/moveToFirst</dt><dd> move the cursor to the first record</dd>
156 <dt>.uno:FormSlots/moveToPrev</dt><dd> move the cursor to the previous record</dd>
157 <dt>.uno:FormSlots/moveToNext</dt><dd> move the cursor to the next record</dd>
158 <dt>.uno:FormSlots/moveToLast</dt><dd> move the cursor to the last record</dd>
159 <dt>.uno:FormSlots/moveToNew</dt><dd> move the cursor to the (one and only) <em>new</em> record</dd>
160 <dt>.uno:FormSlots/undoRecord</dt><dd> undo the changes done so far in the current record</dd>
161 </dl>
162 </p>
164 <p>A concrete implementation of this service may offer more or less URLs, but if it offers some of the URLs
165 above, it must stick to the meanings defined above.</p>
167 [optional] interface com::sun::star::frame::XDispatchProviderInterception;
170 //=============================================================================
172 }; }; }; }; };
175 #endif