1*d1766043SAndrew Rist/**************************************************************
2cdf0e10cSrcweir *
3*d1766043SAndrew Rist * Licensed to the Apache Software Foundation (ASF) under one
4*d1766043SAndrew Rist * or more contributor license agreements.  See the NOTICE file
5*d1766043SAndrew Rist * distributed with this work for additional information
6*d1766043SAndrew Rist * regarding copyright ownership.  The ASF licenses this file
7*d1766043SAndrew Rist * to you under the Apache License, Version 2.0 (the
8*d1766043SAndrew Rist * "License"); you may not use this file except in compliance
9*d1766043SAndrew Rist * with the License.  You may obtain a copy of the License at
10*d1766043SAndrew Rist *
11*d1766043SAndrew Rist *   http://www.apache.org/licenses/LICENSE-2.0
12*d1766043SAndrew Rist *
13*d1766043SAndrew Rist * Unless required by applicable law or agreed to in writing,
14*d1766043SAndrew Rist * software distributed under the License is distributed on an
15*d1766043SAndrew Rist * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
16*d1766043SAndrew Rist * KIND, either express or implied.  See the License for the
17*d1766043SAndrew Rist * specific language governing permissions and limitations
18*d1766043SAndrew Rist * under the License.
19*d1766043SAndrew Rist *
20*d1766043SAndrew Rist *************************************************************/
21*d1766043SAndrew Rist
22*d1766043SAndrew Rist
23cdf0e10cSrcweir#ifndef __com_sun_star_ucb_TransientDocumentsContentProvider_idl__
24cdf0e10cSrcweir#define __com_sun_star_ucb_TransientDocumentsContentProvider_idl__
25cdf0e10cSrcweir
26cdf0e10cSrcweir#ifndef __com_sun_star_ucb_XContentProvider_idl__
27cdf0e10cSrcweir#include <com/sun/star/ucb/XContentProvider.idl>
28cdf0e10cSrcweir#endif
29cdf0e10cSrcweir
30cdf0e10cSrcweir//=============================================================================
31cdf0e10cSrcweir
32cdf0e10cSrcweirmodule com { module sun { module star { module ucb {
33cdf0e10cSrcweir
34cdf0e10cSrcweir//=============================================================================
35cdf0e10cSrcweir/** The Transient Documents Content Provider (TDCP) implements a
36cdf0e10cSrcweir    <type>ContentProvider</type> for the <type>UniversalContentBroker</type>
37cdf0e10cSrcweir	(UCB).
38cdf0e10cSrcweir
39cdf0e10cSrcweir    <p>It provides access to the hierachical structure of the documents that
40cdf0e10cSrcweir    are active in a running OpenOffice.org process. As long as a document was
41cdf0e10cSrcweir    not closed, the TDCP can access it. All documents that have been loaded -
42cdf0e10cSrcweir    regardless of their persistent document format (sxw, doc, sxc, xls, ...)
43cdf0e10cSrcweir    or that have been created  but not yet saved to any storage medium, are
44cdf0e10cSrcweir    supported. The TDCP is not able to load any documents itself. This is
45cdf0e10cSrcweir    exclusively done by the OpenOffice.org document handling framework. The
46cdf0e10cSrcweir    document contents provided by the TDCP represent live data, which may
47cdf0e10cSrcweir    differ from any persistent representation of the document, for instance,
48cdf0e10cSrcweir    because the user modified the document after loading, but did not yet save
49cdf0e10cSrcweir    it.
50cdf0e10cSrcweir
51cdf0e10cSrcweir    @see TransientDocumentsRootContent
52cdf0e10cSrcweir    @see TransientDocumentsDocumentContent
53cdf0e10cSrcweir    @see TransientDocumentsFolderContent
54cdf0e10cSrcweir    @see TransientDocumentsStreamContent
55cdf0e10cSrcweir
56cdf0e10cSrcweir    @since OOo 2.0
57cdf0e10cSrcweir*/
58cdf0e10cSrcweirservice TransientDocumentsContentProvider
59cdf0e10cSrcweir{
60cdf0e10cSrcweir	//-------------------------------------------------------------------------
61cdf0e10cSrcweir    /** provides four different types of contents: Stream, Folder, Document and
62cdf0e10cSrcweir        Root.
63cdf0e10cSrcweir
64cdf0e10cSrcweir		<p>
65cdf0e10cSrcweir
66cdf0e10cSrcweir        <b>TDCP Contents</b>
67cdf0e10cSrcweir		<ol>
68cdf0e10cSrcweir		<li>
69cdf0e10cSrcweir        A TDCP Stream (<type>TransientDocumentsStreamContent</type>) is a
70cdf0e10cSrcweir        content which represents a data stream of an Office document. It is
71cdf0e10cSrcweir        contained in a TDCP Folder or TDCP Document. A TDCP Stream has no
72cdf0e10cSrcweir        children.
73cdf0e10cSrcweir		</li>
74cdf0e10cSrcweir		<li>
75cdf0e10cSrcweir        A TDCP Folder (<type>TransientDocumentsFolderContent</type>) is a
76cdf0e10cSrcweir        container for other TDCP Folders and TDCP Streams. It may be contained
77cdf0e10cSrcweir        in another TDCP Folder or in a TDCP Document.
78cdf0e10cSrcweir		</li>
79cdf0e10cSrcweir		<li>
80cdf0e10cSrcweir        A TDCP Document (<type>TransientDocumentsDocumentContent</type>)
81cdf0e10cSrcweir        represents the root folder of a transient document. It is a container
82cdf0e10cSrcweir        for other TDCP Folders and TDCP Streams. It is always a child of the
83cdf0e10cSrcweir        TDCP Root.
84cdf0e10cSrcweir		</li>
85cdf0e10cSrcweir        <li>
86cdf0e10cSrcweir        There is at most one instance of a TDCP Root
87cdf0e10cSrcweir        (<type>TransientDocumentsRootContent</type>) at a time. All other TDCP
88cdf0e10cSrcweir        contents are children of this folder. The TDCP Root Folder can contain
89cdf0e10cSrcweir        only TDCP Documents. It has the fixed URL "vnd.sun.star.tdoc:/".
90cdf0e10cSrcweir        </li>
91cdf0e10cSrcweir		</ol>
92cdf0e10cSrcweir
93cdf0e10cSrcweir        <p><b>URL Scheme for TDCP Contents</b>
94cdf0e10cSrcweir
95cdf0e10cSrcweir        <p>Each TDCP content has an identifier corresponding to the following
96cdf0e10cSrcweir        scheme:
97cdf0e10cSrcweir
98cdf0e10cSrcweir        <ul>
99cdf0e10cSrcweir        <li>
100cdf0e10cSrcweir        tdcp-URL   = "vnd.sun.star.tdoc:" abs-path
101cdf0e10cSrcweir        </li>
102cdf0e10cSrcweir        <li>
103cdf0e10cSrcweir        abs-path   = +( "/" segment )
104cdf0e10cSrcweir        </li>
105cdf0e10cSrcweir        <li>
106cdf0e10cSrcweir        segment    = *( pchar )
107cdf0e10cSrcweir        </li>
108cdf0e10cSrcweir        <li>
109cdf0e10cSrcweir        pchar      = unreserved | escaped | ":" | "@" | "&" | "=" | "+" | "$" | ","
110cdf0e10cSrcweir        </li>
111cdf0e10cSrcweir        <li>
112cdf0e10cSrcweir        unreserved = alphanum | mark
113cdf0e10cSrcweir        </li>
114cdf0e10cSrcweir        <li>
115cdf0e10cSrcweir        mark       = "-" | "_" | "." | "!" | "~" | "*" | "'" | "("  | ")"
116cdf0e10cSrcweir        </li>
117cdf0e10cSrcweir        <li>
118cdf0e10cSrcweir        escaped    = "%" hex hex
119cdf0e10cSrcweir        </li>
120cdf0e10cSrcweir        </ul>
121cdf0e10cSrcweir
122cdf0e10cSrcweir        <p>Examples:
123cdf0e10cSrcweir
124cdf0e10cSrcweir        <ul>
125cdf0e10cSrcweir        <li>
126cdf0e10cSrcweir        vnd.sun.star.tdoc:/
127cdf0e10cSrcweir        ( The TDCP Root  )
128cdf0e10cSrcweir        </li>
129cdf0e10cSrcweir        <li>
130cdf0e10cSrcweir        vnd.sun.star.tdoc:/22
131cdf0e10cSrcweir        ( The document with the id 22 )
132cdf0e10cSrcweir        </li>
133cdf0e10cSrcweir        <li>
134cdf0e10cSrcweir        vnd.sun.star.tdoc:/22/
135cdf0e10cSrcweir        ( The document with the id 22 )
136cdf0e10cSrcweir        </li>
137cdf0e10cSrcweir        <li>
138cdf0e10cSrcweir        vnd.sun.star.tdoc:/42/folder/subfolder
139cdf0e10cSrcweir        ( The folder/stream named subfolder contained in folder named folder,
140cdf0e10cSrcweir        which is contained in the document with the id 42 )
141cdf0e10cSrcweir        </li>
142cdf0e10cSrcweir        </ul>
143cdf0e10cSrcweir
144cdf0e10cSrcweir        </p>
145cdf0e10cSrcweir     */
146cdf0e10cSrcweir	interface com::sun::star::ucb::XContentProvider;
147cdf0e10cSrcweir
148cdf0e10cSrcweir};
149cdf0e10cSrcweir
150cdf0e10cSrcweir//=============================================================================
151cdf0e10cSrcweir
152cdf0e10cSrcweir}; }; }; };
153cdf0e10cSrcweir
154cdf0e10cSrcweir#endif
155