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: MailMerge.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 ************************************************************************/
30 #ifndef __com_sun_star_text_MailMerge_idl__
31 #define __com_sun_star_text_MailMerge_idl__
33 #ifndef __com_sun_star_task_XJob_idl__
34 #include
<com
/sun
/star
/task
/XJob.idl
>
36 #ifndef __com_sun_star_sdbc_XResultSet_idl__
37 #include
<com
/sun
/star
/sdbc
/XResultSet.idl
>
39 #ifndef __com_sun_star_sdbc_XConnection_idl__
40 #include
<com
/sun
/star
/sdbc
/XConnection.idl
>
42 #ifndef __com_sun_star_frame_XModel_idl__
43 #include
<com
/sun
/star
/frame
/XModel.idl
>
45 #ifndef __com_sun_star_beans_XPropertySet_idl__
46 #include
<com
/sun
/star
/beans
/XPropertySet.idl
>
48 #ifndef __com_sun_star_text_XMailMergeBroadcaster_idl__
49 #include
<com
/sun
/star
/text
/XMailMergeBroadcaster.idl
>
51 #ifndef __com_sun_star_sdb_DataAccessDescriptor_idl__
52 #include
<com
/sun
/star
/sdb
/DataAccessDescriptor.idl
>
55 //=============================================================================
57 module com
{ module sun
{ module star
{ module text
{
59 //=============================================================================
61 /** Gives access to mail merge functionality.
65 published service MailMerge
67 /** interface to execute the mail merge action.
69 <p>The <member scope="com::sun::star::task">XJob::execute</member>
70 method of the interface accepts exactly the same properties
71 as provided by this service in its argument sequence.</p>
73 <p>The default values for the properties to be used in the method
74 call are those given by this service. If a property is also listed
75 in the argument sequence that value will be used for the call.
76 The value of the property in this service will remain unchanged
79 interface com
::sun
::star
::task
::XJob
;
81 /** interface to access the services properties.
83 interface com
::sun
::star
::beans
::XPropertySet
;
85 /** interface to notify mail merge listeners.
87 [optional] interface com
::sun
::star
::text
::XMailMergeBroadcaster
;
89 //=============================================================================
91 /* database properties */
93 //=============================================================================
94 /** allows to specify the data which the mail merge should be based on.
96 <p>This service describe the interaction between all data access related properties,
97 namely <member>DataSourceName</member>, <member>Command</member>, <member>CommandType</member>,
98 <member>Connection</member>, <member>Selection</member>, <member>ResultSet</member>,
99 <member>Filter</member> and <member>EscapeProcessing</member>
101 service com
::sun
::star
::sdb
::DataAccessDescriptor
;
103 /** contains the name of the data source that is to be used for merging.
105 <p>For the interaction of this property with other data access relevant properties, see
106 the <type scope="com::sun::star::sdb">DataAccessDescriptor</type> service.</p>
108 [property
] string DataSourceName
;
110 //=============================================================================
112 /** determines the type of the database command as
113 described in <type scope="com::sun::star::sdb">CommandType</type>
115 <p>For the interaction of this property with other data access relevant properties, see
116 the <type scope="com::sun::star::sdb">DataAccessDescriptor</type> service.</p>
118 [property
] long CommandType
;
120 //=============================================================================
122 /** contains the database command.
124 <p>For the interaction of this property with other data access relevant properties, see
125 the <type scope="com::sun::star::sdb">DataAccessDescriptor</type> service.</p>
127 [property
] string Command
;
129 //=============================================================================
131 /** provides access to a
132 <type scope="com::sun::star::sdbc">XResultSet</type> of
133 a <type scope="com::sun::star::sdbc">ResultSet</type> service.
135 <p>Note that any superservices of <type scope="com::sun::star::sdbc">ResultSet</type>
136 are also allowed. Especially, this member can denote an instance of the
137 <type scope="com::sun::star::sdb">RowSet</type>, or an instance obtained
138 by calling <member scope="com::sun::star::sdb">XResultSetAccess::createResultSet</member>
139 on such a <type scope="com::sun::star::sdb">RowSet</type>. This becomes important in
140 conjunction with the <member>Selection</member> property.</p>
142 <p>For the interaction of this property with other data access relevant properties, see
143 the <type scope="com::sun::star::sdb">DataAccessDescriptor</type> service.</p>
145 [property
] com
::sun
::star
::sdbc
::XResultSet ResultSet
;
147 //=============================================================================
149 /** contains the connection to the database.
151 <p>For the interaction of this property with other data access relevant properties, see
152 the <type scope="com::sun::star::sdb">DataAccessDescriptor</type> service.</p>
154 [property
] com
::sun
::star
::sdbc
::XConnection ActiveConnection
;
156 //=============================================================================
158 /** contains a selection that refers to bookmarks of the ResultSet.
160 <p>This property is relevant in conjunction with the <member>ResultSet</member>
161 only. A single element of this array describes a bookmark relative to the result set.<br/>
162 Note that this implies that the <member>ResultSet</member> needs to support the
163 <type scope="com::sun::star::sdbcx">XRowLocate</type> interface.</p>
165 <p>If this array is empty, the whole result set, as described by <member>ResultSet</member>
166 respectively the triple (<member>DataSourceName</member>, <member>DataCommandType</member>,
167 <member>DataCommand</member>).</p>
169 <p>For the interaction of this property with other data access relevant properties, see
170 the <type scope="com::sun::star::sdb">DataAccessDescriptor</type> service.</p>
172 [property
] sequence
< any
> Selection
;
174 //=============================================================================
176 /** returns if escape processing is on or off.
178 <p>For the interaction of this property with other data access relevant properties, see
179 the <type scope="com::sun::star::sdb">DataAccessDescriptor</type> service.</p>
181 [property
] boolean EscapeProcessing
;
183 //=============================================================================
185 /** contains a filter expression for an SQL statement.
187 <p>For the interaction of this property with other data access relevant properties, see
188 the <type scope="com::sun::star::sdb">DataAccessDescriptor</type> service.</p>
190 [property
] string Filter
;
192 //=============================================================================
194 /* input properties */
196 //=============================================================================
198 /** contains the URL of a text document that is to be processed.
200 <p>If this property is not set an empty document is created.</p>
202 [property
] string DocumentURL
;
204 //=============================================================================
206 /** provides access to the model of the document to be processed.
208 <p>This property will automatically be set to the documents model
209 if a document URL was set.</p>
211 [property
, readonly] com
::sun
::star
::frame
::XModel Model
;
213 //=============================================================================
215 /* output properties */
217 //=============================================================================
219 /** determines the destination of the mail merge action.
221 @see com::sun::star::text::MailMergeType
223 [property
] short OutputType
;
225 //=============================================================================
227 /** determines whether single print jobs will be generated per output document.
229 <p>This property is only evaluated for printer output.</p>
231 [property
] boolean SinglePrintJobs
;
233 //=============================================================================
235 /** contains the path where generated files are created.
237 <p>If "OutputURL" or "FileNamePrefix" are empty the missing value is
238 generated from the location or title of the source documents.</p>
240 <p>This property is only evaluated for file output.</p>
242 [property
] string OutputURL
;
244 //=============================================================================
246 /** determines whether file names of created files are generated using
247 the content of a database column.
249 <p>This property is only evaluated for file output.</p>
251 [property
] boolean FileNameFromColumn
;
253 //=============================================================================
255 /** contains the name of the column to generate the output file names.
257 <p>If FileNameFromColumn is true the content of the related column
258 is added to the OutputURL.</p>
259 <p>If "OutputURL" or "FileNamePrefix" are empty the missing value is
260 generated from the location or title of the source documents.</p>
262 <p>This property is only evaluated for file output.</p>
264 [property
] string FileNamePrefix
;
266 //=============================================================================
268 /** Contains the password of the outgoing mail server. It is necessary to set this
269 if the password is not already stored in the configuration for security reasons.
271 <p>This property is only evaluated for e-Mail output.</p>
275 [property
, optional] string OutServerPassword
;
276 //=============================================================================
278 /** Contains the password of the incoming mail server. It is necessary to set this
279 if the mail server configuration is set to 'SMTP after POP' authentication and
280 the password is not already stored in the configuration for security reasons.
282 <p>This property is only evaluated for e-Mail output.</p>
286 [property
, optional] string InServerPassword
;
287 //=============================================================================
289 /** contains the subject of the e-Mail message.
291 <p>This property is only evaluated for e-Mail output.</p>
294 [property
, optional] string Subject
;
296 //=============================================================================
298 /** contains the name of the data base column that contains the e-Mail address
301 <p>This property is only evaluated for e-Mail output.</p>
305 [property
, optional] string AddressFromColumn
;
307 //=============================================================================
309 /** determines that the created mail merge document is sent as body in HTML format.
310 This property is only valid if the propery "SendAsAttachment" is set to <false/>.
312 <p>This property is only evaluated for e-Mail output.</p>
316 [property
, optional] boolean SendAsHTML
;
318 //=============================================================================
321 /** determines that the created mail merge document is sent as attachment.
323 <p>This property is only evaluated for e-Mail output.</p>
327 [property
, optional] boolean SendAsAttachment
;
329 //=============================================================================
331 /** contains the text of the mail body.
332 This property is only valid if the property "SendAsAttachment" is set to <true/>
333 <p>This property is only evaluated for e-Mail output.</p>
337 [property
, optional] string MailBody
;
339 //=============================================================================
341 /** contains the name of the attachment.
342 This property is only valid if "SendAsAttachment" is set to <true/>.
344 <p>This property is only evaluated for e-Mail output.</p>
348 [property
, optional] string AttachmentName
;
350 //=============================================================================
352 /** contains the name of the document filter to save the attached mail merge document.
353 This property is only valid if "SendAsAttachment" is set to <true/>.
355 <p>This property is only evaluated for e-Mail output.</p>
359 [property
, optional] string AttachmentFilter
;
361 //=============================================================================
363 /** contains a list of e-Mail addresses to
364 <p>This property is only evaluated for e-Mail output.</p>
368 [property
, optional] sequence
< string > CopiesTo
;
370 //=============================================================================
373 <p>This property is only evaluated for e-Mail output.</p>
377 [property
, optional] sequence
< string > BlindCopiesTo
;
380 //=============================================================================
382 /** determines that the output of the mail merge is save in one single file.
383 <p>This property is only evaluated for file output.</p>
387 [property
, optional] boolean SaveAsSingleFile
;
389 //=============================================================================
391 /** contains the name of the document filter to save the output file(s).
392 <p>This property is only evaluated for file output.</p>
396 [property
, optional] string SaveFilter
;
398 //=============================================================================
400 /** contains the properties that are defined in <com::sun::star::view::PrintOptions>.
402 <p>This property is only evaluated for printer output.</p>
406 [property
, optional] sequence
< com
::sun
::star
::beans
::PropertyValue
> PrintOptions
;
411 //=============================================================================