/**************************************************************
*
* Licensed to the Apache Software Foundation (ASF) under one
* or more contributor license agreements. See the NOTICE file
* distributed with this work for additional information
* regarding copyright ownership. The ASF licenses this file
* to you under the Apache License, Version 2.0 (the
* "License"); you may not use this file except in compliance
* with the License. You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing,
* software distributed under the License is distributed on an
* "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
* KIND, either express or implied. See the License for the
* specific language governing permissions and limitations
* under the License.
*
*************************************************************/
#ifndef __com_sun_star_sdb_application_CopyTableWizard_idl__
#define __com_sun_star_sdb_application_CopyTableWizard_idl__
#ifndef __com_sun_star_sdb_application_XCopyTableWizard_idl__
#include There are various cases where the wizard needs to interact with the user (except of
course the obvious case to display and operate the wizard dialog itself). For those cases,
an interaction handler is needed, which is used for
SQLException
, usually) that happened.
When you do not specify an interaction handler by using the
ConnectionResource
, or a connection
not obtained from a data source), or if the copy target's database document cannot provide
an interaction handler, a newly-created instance of an interaction handler is used.
There's one exception to the above, however: Upon creating the copy table wizard,
the copy source and the copy target descriptors are used to create a Connection. For any
interaction during this phase - including, for instance, necessary authentication -, the
interaction handler of the respective data source is used, no matter what you specified
in
At creation time, an attempt will be made to obtain the connections described
by
If the connection has been newly created by the wizard (e.g. because the
data access descriptor specified a DataSource
instead of an ActiveConnection
),
then this connection will be disposed upon disposal of the wizard.
The following members of the DataAccessDescriptor
are supported, and evaluated
in the given order:
ActiveConnection
DataSourceName
DatabaseLocation
ConnectionResource
ConnectionInfo
Command
CommandType
Command
and CommandType
are required.
Additionally to the obvious restrictions (such as that creating a view is not possible if the copy source and the copy destination denote different databases), the following restrictions apply to the settings, and possible combinations:
ConnectionResource
, or an
ActiveConnection
which implements an QUERY
will be rejected.Filter
, Order
, HavingClause
and GroupBy
are unsupported at the moment.Only DataSourceName
, DatabaseLocation
, ActiveConnection
are supported, effectively describing the target connection to copy the data to. They're evaluated
in the order mentioned here, so if multiple of the are present, only the first one is evaluated.
Also, at the moment the connection which is implied by either of the settings above
must support the
Note that creating a view (see
Source
or Destination
is Source
or Destination
are not sufficient
to describe a database connection.Source
is not sufficient to describe the to-be-copied dataSource
or Destination
contain unsupported settings.DataSourceName
member.
@see ::com::sun::star::sdb::DataAccessDescriptor
*/
create(
[in] ::com::sun::star::beans::XPropertySet Source,
[in] ::com::sun::star::beans::XPropertySet Destination
)
raises ( ::com::sun::star::lang::IllegalArgumentException
, ::com::sun::star::sdbc::SQLException
, ::com::sun::star::lang::WrappedTargetException
);
/** creates an executable wizard dialog, which is to guide the user through copying
a table from one database to another.
The only difference to the createWithInteractionHandler
takes an additional argument, which
can be used to intercept interactions (such as error messages) during the wizard
run.
When specifying this parameter, you should use an implementation
supporting the