Version 5.2.6.1, tag libreoffice-5.2.6.1
[LibreOffice.git] / offapi / com / sun / star / frame / XDispatchRecorder.idl
blob8b0071fef2af3908de64c1bfbf766e02f6c99923
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_frame_XDispatchRecorder_idl__
20 #define __com_sun_star_frame_XDispatchRecorder_idl__
22 #include <com/sun/star/uno/XInterface.idl>
23 #include <com/sun/star/util/URL.idl>
24 #include <com/sun/star/beans/PropertyValue.idl>
27 module com { module sun { module star { module frame {
29 published interface XFrame;
31 /** provides recording functionality of dispatches
33 <p>
34 With such recorder it will be possible to record requests of type
35 XDispatch by using additional interface
36 XRecordableDispatch. The result of that will be a
37 a script which can be used to start the dispatch at later time again.
38 Such recorder objects are available on a XDispatchRecorderSupplier
39 which is provided by the Frame service.
40 </p>
42 @see Frame
43 @see XDispatchRecorderSupplier
45 @since OOo 1.1.2
47 published interface XDispatchRecorder: com::sun::star::uno::XInterface
49 /** initializes the recorder by passing the frame for which all
50 macro statements shall be recorded
52 @param Frame
53 it includes the document on which such requests shall be recorded
55 void startRecording( [in] com::sun::star::frame::XFrame Frame );
57 /** stops the recording process
59 <p>
60 Must be called in pairs with XDispatchRecorder::startRecording().
61 </p>
63 @attention The recorder uses this method to control the lifetime of its internal
64 used macro buffer. It will be cleared here. So the macro must be fetched
65 before endRecording() is called.
67 @see getRecordedMacro()
69 void endRecording();
71 /** records a single dispatch call identified by its command URL
73 @param URL
74 the full parsed command URL
76 @param Arguments
77 optional arguments for the command URL
78 <br>
79 (see com::sun::star::document::MediaDescriptor
80 for further information)
82 void recordDispatch(
83 [in] com::sun::star::util::URL URL,
84 [in] sequence<com::sun::star::beans::PropertyValue> Arguments);
86 /** records a single dispatch call identified by its command URL, but
87 comments it out
89 <p>
90 This way calls that failed on execution can be documented.
91 </p>
93 @param URL
94 the full parsed command URL
96 @param Arguments
97 optional arguments for the command URL
98 <br>
99 (see com::sun::star::document::MediaDescriptor
100 for further information)
102 void recordDispatchAsComment(
103 [in] com::sun::star::util::URL URL,
104 [in] sequence<com::sun::star::beans::PropertyValue> Arguments);
106 /** returns the recorded source code
109 This method must be used before endRecording() is called!
110 Otherwise the macro will be released.
111 </p>
113 @returns
114 the recorded data as a string which can be interpreted as a script
116 string getRecordedMacro();
120 }; }; }; };
122 #endif
124 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */