1*3398c5b8SAndrew Rist /**************************************************************
2cdf0e10cSrcweir  *
3*3398c5b8SAndrew Rist  * Licensed to the Apache Software Foundation (ASF) under one
4*3398c5b8SAndrew Rist  * or more contributor license agreements.  See the NOTICE file
5*3398c5b8SAndrew Rist  * distributed with this work for additional information
6*3398c5b8SAndrew Rist  * regarding copyright ownership.  The ASF licenses this file
7*3398c5b8SAndrew Rist  * to you under the Apache License, Version 2.0 (the
8*3398c5b8SAndrew Rist  * "License"); you may not use this file except in compliance
9*3398c5b8SAndrew Rist  * with the License.  You may obtain a copy of the License at
10*3398c5b8SAndrew Rist  *
11*3398c5b8SAndrew Rist  *   http://www.apache.org/licenses/LICENSE-2.0
12*3398c5b8SAndrew Rist  *
13*3398c5b8SAndrew Rist  * Unless required by applicable law or agreed to in writing,
14*3398c5b8SAndrew Rist  * software distributed under the License is distributed on an
15*3398c5b8SAndrew Rist  * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
16*3398c5b8SAndrew Rist  * KIND, either express or implied.  See the License for the
17*3398c5b8SAndrew Rist  * specific language governing permissions and limitations
18*3398c5b8SAndrew Rist  * under the License.
19*3398c5b8SAndrew Rist  *
20*3398c5b8SAndrew Rist  *************************************************************/
21*3398c5b8SAndrew Rist 
22*3398c5b8SAndrew Rist 
23cdf0e10cSrcweir #ifndef _RETSTRM_HXX
24cdf0e10cSrcweir #define _RETSTRM_HXX
25cdf0e10cSrcweir 
26cdf0e10cSrcweir #include <basic/sbxvar.hxx>
27cdf0e10cSrcweir #include "cmdbasestream.hxx"
28cdf0e10cSrcweir 
29cdf0e10cSrcweir class SvStream;
30cdf0e10cSrcweir 
31cdf0e10cSrcweir class RetStream: public CmdBaseStream
32cdf0e10cSrcweir {
33cdf0e10cSrcweir 
34cdf0e10cSrcweir public:
35cdf0e10cSrcweir 	RetStream();
36cdf0e10cSrcweir 	~RetStream();
37cdf0e10cSrcweir 
38cdf0e10cSrcweir     using CmdBaseStream::GenError;
39cdf0e10cSrcweir //  new
40cdf0e10cSrcweir 	void GenError( rtl::OString aUId, String aString );
41cdf0e10cSrcweir 
42cdf0e10cSrcweir     using CmdBaseStream::GenReturn;
GenReturn(comm_USHORT nRet,comm_ULONG nNr)43cdf0e10cSrcweir     void GenReturn( comm_USHORT nRet, comm_ULONG nNr ){CmdBaseStream::GenReturn( nRet, nNr );}
GenReturn(comm_USHORT nRet,rtl::OString aUId,comm_ULONG nNr)44cdf0e10cSrcweir 	void GenReturn( comm_USHORT nRet, rtl::OString aUId, comm_ULONG nNr ){CmdBaseStream::GenReturn( nRet, &aUId, nNr );}
GenReturn(comm_USHORT nRet,rtl::OString aUId,comm_BOOL bBool)45cdf0e10cSrcweir     void GenReturn( comm_USHORT nRet, rtl::OString aUId, comm_BOOL bBool ){CmdBaseStream::GenReturn( nRet, &aUId, bBool );}
46cdf0e10cSrcweir 
47cdf0e10cSrcweir // MacroRecorder
GenReturn(comm_USHORT nRet,rtl::OString aUId,comm_USHORT nMethod)48cdf0e10cSrcweir     void GenReturn( comm_USHORT nRet, rtl::OString aUId, comm_USHORT nMethod ){CmdBaseStream::GenReturn( nRet, &aUId, nMethod );} // also used outside MacroRecorder
GenReturn(comm_USHORT nRet,rtl::OString aUId,comm_USHORT nMethod,comm_BOOL bBool)49cdf0e10cSrcweir 	void GenReturn( comm_USHORT nRet, rtl::OString aUId, comm_USHORT nMethod, comm_BOOL bBool ){CmdBaseStream::GenReturn( nRet, &aUId, nMethod, bBool );}
GenReturn(comm_USHORT nRet,rtl::OString aUId,comm_USHORT nMethod,comm_ULONG nNr)50cdf0e10cSrcweir 	void GenReturn( comm_USHORT nRet, rtl::OString aUId, comm_USHORT nMethod, comm_ULONG nNr ){CmdBaseStream::GenReturn( nRet, &aUId, nMethod, nNr );}
51cdf0e10cSrcweir 
52cdf0e10cSrcweir //  new
53cdf0e10cSrcweir     void GenReturn( sal_uInt16 nRet, rtl::OString aUId, String aString );
54cdf0e10cSrcweir 	void GenReturn( sal_uInt16 nRet, rtl::OString aUId, comm_ULONG nNr, String aString, sal_Bool bBool );
55cdf0e10cSrcweir 
56cdf0e10cSrcweir // needed for RemoteCommand and Profiling
57cdf0e10cSrcweir 	void GenReturn( sal_uInt16 nRet, sal_uInt16 nMethod, SbxValue &aValue );
58cdf0e10cSrcweir     void GenReturn( sal_uInt16 nRet, sal_uInt16 nMethod, String aString );
59cdf0e10cSrcweir 
60cdf0e10cSrcweir // MacroRecorder
61cdf0e10cSrcweir     void GenReturn( sal_uInt16 nRet, rtl::OString aUId, comm_USHORT nMethod, String aString );
62cdf0e10cSrcweir     void GenReturn( sal_uInt16 nRet, rtl::OString aUId, comm_USHORT nMethod, String aString, sal_Bool bBool );
63cdf0e10cSrcweir 
64cdf0e10cSrcweir     void Reset();
65cdf0e10cSrcweir 	SvStream* GetStream();
66cdf0e10cSrcweir 
67cdf0e10cSrcweir 
68cdf0e10cSrcweir 
69cdf0e10cSrcweir     using CmdBaseStream::Write;
Write(comm_USHORT nNr)70cdf0e10cSrcweir     void Write( comm_USHORT nNr ){CmdBaseStream::Write( nNr );}
Write(comm_ULONG nNr)71cdf0e10cSrcweir     void Write( comm_ULONG nNr ){CmdBaseStream::Write( nNr );}
Write(comm_BOOL bBool)72cdf0e10cSrcweir 	void Write( comm_BOOL bBool ){CmdBaseStream::Write( bBool );}
73cdf0e10cSrcweir //  new
74cdf0e10cSrcweir 	void Write( SbxValue &aValue );
75cdf0e10cSrcweir 
76cdf0e10cSrcweir // Complex Datatypes to be handled system dependent
77cdf0e10cSrcweir 	virtual void Write( rtl::OString* pId );
78cdf0e10cSrcweir     virtual void Write( String *pString );
79cdf0e10cSrcweir 
80cdf0e10cSrcweir 	SvStream *pSammel;
81cdf0e10cSrcweir };
82cdf0e10cSrcweir 
83cdf0e10cSrcweir #endif
84