1 /* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
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 .
20 #ifndef _INPUSTREAM_HXX_
21 #define _INPUSTREAM_HXX_
23 #include <rtl/ustring.hxx>
24 #include <osl/file.hxx>
25 #include <cppuhelper/weak.hxx>
26 #include <com/sun/star/uno/XInterface.hpp>
27 #include <com/sun/star/io/XSeekable.hpp>
28 #include <com/sun/star/io/XInputStream.hpp>
29 #include <com/sun/star/ucb/XContentProvider.hpp>
34 // forward declaration
36 class XInputStream_impl
37 : public cppu::OWeakObject
,
38 public com::sun::star::io::XInputStream
,
39 public com::sun::star::io::XSeekable
43 XInputStream_impl( const OUString
& aUncPath
);
45 virtual ~XInputStream_impl();
48 * Returns an error code as given by filerror.hxx
51 bool SAL_CALL
CtorSuccess();
53 virtual com::sun::star::uno::Any SAL_CALL
55 const com::sun::star::uno::Type
& rType
)
56 throw( com::sun::star::uno::RuntimeException
);
68 virtual sal_Int32 SAL_CALL
70 com::sun::star::uno::Sequence
< sal_Int8
>& aData
,
71 sal_Int32 nBytesToRead
)
72 throw( com::sun::star::io::NotConnectedException
,
73 com::sun::star::io::BufferSizeExceededException
,
74 com::sun::star::io::IOException
,
75 com::sun::star::uno::RuntimeException
);
77 virtual sal_Int32 SAL_CALL
79 com::sun::star::uno::Sequence
< sal_Int8
>& aData
,
80 sal_Int32 nMaxBytesToRead
)
81 throw( com::sun::star::io::NotConnectedException
,
82 com::sun::star::io::BufferSizeExceededException
,
83 com::sun::star::io::IOException
,
84 com::sun::star::uno::RuntimeException
);
88 sal_Int32 nBytesToSkip
)
89 throw( com::sun::star::io::NotConnectedException
,
90 com::sun::star::io::BufferSizeExceededException
,
91 com::sun::star::io::IOException
,
92 com::sun::star::uno::RuntimeException
);
94 virtual sal_Int32 SAL_CALL
97 throw( com::sun::star::io::NotConnectedException
,
98 com::sun::star::io::IOException
,
99 com::sun::star::uno::RuntimeException
);
101 virtual void SAL_CALL
104 throw( com::sun::star::io::NotConnectedException
,
105 com::sun::star::io::IOException
,
106 com::sun::star::uno::RuntimeException
);
108 virtual void SAL_CALL
111 throw( com::sun::star::lang::IllegalArgumentException
,
112 com::sun::star::io::IOException
,
113 com::sun::star::uno::RuntimeException
);
115 virtual sal_Int64 SAL_CALL
118 throw( com::sun::star::io::IOException
,
119 com::sun::star::uno::RuntimeException
);
121 virtual sal_Int64 SAL_CALL
124 throw( com::sun::star::io::IOException
,
125 com::sun::star::uno::RuntimeException
);
134 } // end namespace XInputStream_impl
138 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */