1 /************************************************************************* 2 * 3 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 4 * 5 * Copyright 2000, 2010 Oracle and/or its affiliates. 6 * 7 * OpenOffice.org - a multi-platform office productivity suite 8 * 9 * This file is part of OpenOffice.org. 10 * 11 * OpenOffice.org is free software: you can redistribute it and/or modify 12 * it under the terms of the GNU Lesser General Public License version 3 13 * only, as published by the Free Software Foundation. 14 * 15 * OpenOffice.org is distributed in the hope that it will be useful, 16 * but WITHOUT ANY WARRANTY; without even the implied warranty of 17 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 18 * GNU Lesser General Public License version 3 for more details 19 * (a copy is included in the LICENSE file that accompanied this code). 20 * 21 * You should have received a copy of the GNU Lesser General Public License 22 * version 3 along with OpenOffice.org. If not, see 23 * <http://www.openoffice.org/license.html> 24 * for a copy of the LGPLv3 License. 25 * 26 ************************************************************************/ 27 28 /************************************************************************* 29 * 30 * ATTENTION 31 * This file is intended to work inside and outside the StarOffice environment. 32 * Only adaption of file commtypes.hxx should be necessary. Else it is a bug! 33 * 34 ************************************************************************/ 35 36 #ifndef _AUTOMATION_ICOMMSTREAM_HXX_ 37 #define _AUTOMATION_ICOMMSTREAM_HXX_ 38 39 #include <automation/commtypes.hxx> 40 41 class ICommStream 42 { 43 public: 44 45 ICommStream(){} 46 virtual ~ICommStream(){} 47 48 virtual ICommStream& operator>>( comm_USHORT& rUShort )=0; 49 virtual ICommStream& operator>>( comm_ULONG& rULong )=0; 50 virtual ICommStream& operator>>( comm_BOOL& rChar )=0; 51 52 virtual ICommStream& operator<<( comm_USHORT nUShort )=0; 53 virtual ICommStream& operator<<( comm_ULONG nULong )=0; 54 virtual ICommStream& operator<<( comm_BOOL nChar )=0; 55 56 virtual comm_ULONG Read( void* pData, comm_ULONG nSize )=0; 57 virtual comm_ULONG Write( const void* pData, comm_ULONG nSize )=0; 58 59 virtual comm_BOOL IsEof() const=0; 60 virtual comm_ULONG SeekRel( long nPos )=0; 61 62 }; 63 64 #endif 65