From 1157563ae83b41998a4982c06299780aba7830d4 Mon Sep 17 00:00:00 2001 From: Martin Gallwey Date: Wed, 4 Jul 2001 13:56:37 +0000 Subject: #86708# changes for pack'n'go feature (incomplete) --- package/inc/ByteChucker.hxx | 17 ++++++++++++----- 1 file changed, 12 insertions(+), 5 deletions(-) (limited to 'package/inc/ByteChucker.hxx') diff --git a/package/inc/ByteChucker.hxx b/package/inc/ByteChucker.hxx index 2ba8a6c569f2..4b9cbf0b2ae0 100644 --- a/package/inc/ByteChucker.hxx +++ b/package/inc/ByteChucker.hxx @@ -2,9 +2,9 @@ * * $RCSfile: ByteChucker.hxx,v $ * - * $Revision: 1.6 $ + * $Revision: 1.7 $ * - * last change: $Author: mtg $ $Date: 2001-05-31 09:36:05 $ + * last change: $Author: mtg $ $Date: 2001-07-04 14:56:13 $ * * The Contents of this file are made available subject to the terms of * either of the following licenses @@ -68,20 +68,25 @@ #include #endif +class ThreadedBuffer; + class ByteChucker { + friend class ThreadedBuffer; protected: com::sun::star::uno::Reference < com::sun::star::io::XOutputStream > xStream; com::sun::star::uno::Reference < com::sun::star::io::XSeekable > xSeek; - com::sun::star::uno::Sequence < sal_Int8 > a1Sequence, a2Sequence, a4Sequence; - sal_Int8 *p1Sequence, *p2Sequence, *p4Sequence; + com::sun::star::uno::Sequence < sal_Int8 > aBuffer, a1Sequence, a2Sequence, a4Sequence; + sal_Bool bSpannable, bNextWriteIsAtomic; + sal_Int8 * const p1Sequence, * const p2Sequence, * const p4Sequence, * pBuffer; + sal_Int32 nBufferSize, nCurrentBufferPos; public: ByteChucker (com::sun::star::uno::Reference xOstream); ~ByteChucker(); // XOutputStream - void SAL_CALL writeBytes( const ::com::sun::star::uno::Sequence< sal_Int8 >& aData ) + void SAL_CALL writeBytes( const ::com::sun::star::uno::Sequence< sal_Int8 >& aData, sal_Int32 nLength = -1, const sal_Int8 * const pData = NULL) throw(::com::sun::star::io::NotConnectedException, ::com::sun::star::io::BufferSizeExceededException, ::com::sun::star::io::IOException, ::com::sun::star::uno::RuntimeException); void SAL_CALL flush( ) throw(::com::sun::star::io::NotConnectedException, ::com::sun::star::io::BufferSizeExceededException, ::com::sun::star::io::IOException, ::com::sun::star::uno::RuntimeException); @@ -101,6 +106,8 @@ public: ByteChucker& operator << (sal_uInt8 nuInt8); ByteChucker& operator << (sal_uInt16 nuInt16); ByteChucker& operator << (sal_uInt32 nuInt32); + void setSpannable ( sal_Bool bNewSpannable ); + inline sal_Bool isSpannable () { return bSpannable; } }; #endif -- cgit