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: XBinaryStreamResolver.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_document_XBinaryStreamResolver_idl__
31 #define __com_sun_star_document_XBinaryStreamResolver_idl__
33 #ifndef __com_sun_star_uno_XInterface_idl__
34 #include
<com
/sun
/star
/uno
/XInterface.idl
>
36 #ifndef __com_sun_star_io_XInputStream_idl__
37 #include
<com
/sun
/star
/io
/XInputStream.idl
>
39 #ifndef __com_sun_star_io_XOututStream_idl__
40 #include
<com
/sun
/star
/io
/XOutputStream.idl
>
43 //=============================================================================
45 module com
{ module sun
{ module star
{ module document
{
47 //=============================================================================
50 <p>This interface encapsulates functionality to get/resolve binary data streams.
51 It is used to transform binary data to an url or to transform an url to binary
52 data. The binary data is represented through input and output streams.</p>
54 <p>In the case of transforming an url to binary data, the <code>getInputStream</code>
55 method is used. This returns a <type scope="com::sun::star::io">XInputStream</type>
56 from which the binary data, transformed from the given url, can be read.</p>
58 <p>In the case of transforming binary data to an url, a
59 <type scope="com::sun::star::io">XOutputStream</type> is created first to write
60 the binary data to. After this, the <code>resolveOutputStream</code> method can
61 be used to transform the binary data, represented through the
62 <type scope="com::sun::star::io">XOutputStream</type> interface, to an url.</p>
64 published
interface XBinaryStreamResolver
: com
::sun
::star
::uno
::XInterface
66 /** converts the given URL from the source URL namespace to an input stream,
67 from which binary data can be read
69 com
::sun
::star
::io
::XInputStream getInputStream
( [in] string aURL
);
71 /** creates an output stream, to which binary data can be written.
72 After writing, an URL can be retrieved by a call to
73 <method>XBinaryStreamResolver::resolveOutputStream</method>.
75 com
::sun
::star
::io
::XOutputStream createOutputStream
();
77 /** converts the output stream, data has been written to, to an URL in
80 string resolveOutputStream
( [in] com
::sun
::star
::io
::XOutputStream aBinaryStream
);
83 //=============================================================================