blob: e7199c295a745e458d737b1f3e1ce312cc64469e (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
|
/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*
* This file is part of the LibreOffice project.
*
* This Source Code Form is subject to the terms of the Mozilla Public
* License, v. 2.0. If a copy of the MPL was not distributed with this
* file, You can obtain one at http://mozilla.org/MPL/2.0/.
*
* This file incorporates work covered by the following license notice:
*
* 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 .
*/
module com { module sun { module star { module frame {
/** provides a high level API to organize document templates
<p>
Template information is saved as links to the original content
and organized in groups. This data should be persistent and can be
updated by calling special method XDocumentTemplates::update().
A real implementation of this interface can do that on top of
a ucb content provider. Method XDocumentTemplates::getContent()
force that.
</p>
*/
published interface XDocumentTemplates: com::sun::star::uno::XInterface
{
/** provides access to the root of internal used hierarchy
<p>
This content can be used for accessing the groups directly.
</p>
@return
the ucb content for template configuration
*/
com::sun::star::ucb::XContent getContent();
/** creates the template with the given name in the given group using the
data from the storable
@param GroupName
specifies the group
@param TemplateName
specifies the template
@param Storable
specifies the target
@return
`TRUE` if operation was successful
<br>
`FALSE` otherwise
@see XDocumentTemplates::addTemplate()
*/
boolean storeTemplate(
[in] string GroupName,
[in] string TemplateName,
[in] XStorable Storable);
/** creates the template with the given name in the given group using the
given URL
@param GroupName
specifies the group
@param TemplateName
specifies the template
@param SourceURL
specifies the position of template
@return
`TRUE` if operation was successful
<br>
`FALSE` otherwise
@see XDocumentTemplates::storeTemplate()
*/
boolean addTemplate(
[in] string GroupName,
[in] string TemplateName,
[in] string SourceURL);
/** remove a template from specified group
@param GroupName
specifies the group which include the template
@param TemplateName
specifies the template for delete
@return
`TRUE` if operation was successful
<br>
`FALSE` otherwise
*/
boolean removeTemplate(
[in] string GroupName,
[in] string TemplateName);
/** rename a template inside specified group
@param GroupName
specifies the group which include the template
@param OldTemplateName
specifies the template for renaming
@param NewTemplateName
specifies the new name for the template
@return
`TRUE` if operation was successful
<br>
`FALSE` otherwise
*/
boolean renameTemplate(
[in] string GroupName,
[in] string OldTemplateName,
[in] string NewTemplateName);
/** creates a new group
@param GroupName
the name of the group to be created
@return
`TRUE` if operation was successful
<br>
`FALSE` otherwise
*/
boolean addGroup( [in] string GroupName );
/** remove an existing group
@param GroupName
the name of the group to be removed
@return
`TRUE` if operation was successful
<br>
`FALSE` otherwise
*/
boolean removeGroup( [in] string GroupName );
/** rename an existing group
@param OldGroupName
the old name of the group
@param NewGroupName
the new name of the group
@return
`TRUE` if operation was successful
<br>
`FALSE` otherwise
*/
boolean renameGroup(
[in] string OldGroupName,
[in] string NewGroupName);
/** force an update for internal structures
<p>
Because the templates are well known by links and not as direct content
they can be outdated. An update force actualization of that to find
wrong links.
</p>
*/
void update();
};
}; }; }; };
/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
|