1 /* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
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_sdbc_XResultSetUpdate_idl__
20 #define __com_sun_star_sdbc_XResultSetUpdate_idl__
22 #include
<com
/sun
/star
/uno
/XInterface.idl
>
24 #include
<com
/sun
/star
/sdbc
/SQLException.idl
>
26 module com
{ module sun
{ module star
{ module sdbc
{
29 /** provides the possibility to write changes made on a result set back to
32 published
interface XResultSetUpdate
: com
::sun
::star
::uno
::XInterface
35 /** inserts the contents of the insert row into the result set and
36 the database. Must be on the insert row when this method is called.
38 if a database access error occurs.
40 void insertRow
() raises
(SQLException
);
42 /** updates the underlying database with the new contents of the
43 current row. Cannot be called when on the insert row.
45 if a database access error occurs.
47 void updateRow
() raises
(SQLException
);
49 /** deletes the current row from the result set and the underlying
50 database. Cannot be called when on the insert row.
52 if a database access error occurs.
54 void deleteRow
() raises
(SQLException
);
56 /** cancels the updates made to a row.
60 This method may be called after calling an
61 <code>updateXXX</code>
62 method(s) and before calling
63 com::sun::star::sdbc::XResultSetUpdate::updateRow()
64 to rollback the updates made to a row. If no updates have been made or
65 <code>updateRow</code>
66 has already been called, then this method has no
70 if a database access error occurs.
72 void cancelRowUpdates
() raises
(SQLException
);
74 /** moves the cursor to the insert row. The current cursor position is
75 remembered while the cursor is positioned on the insert row.
79 The insert row is a special row associated with an updatable
80 result set. It is essentially a buffer where a new row may
81 be constructed by calling the
82 <code>updateXXX</code>
84 inserting the row into the result set.
88 <code>updateXXX</code>
93 com::sun::star::sdbc::XResultSetUpdate::insertRow()
95 called when the cursor is on the insert row. All of the columns in
96 a result set must be given a value each time this method is
98 <code>insertRow</code>
100 <code>updateXXX</code>
101 must be called before a
103 method can be called on a column value.
106 if a database access error occurs.
108 void moveToInsertRow
() raises
(SQLException
);
110 /** moves the cursor to the remembered cursor position, usually the
111 current row. This method has no effect if the cursor is not on the insert
114 if a database access error occurs.
116 void moveToCurrentRow
() raises
(SQLException
);
122 /*===========================================================================
123 ===========================================================================*/
126 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */