1 /**************************************************************
2  *
3  * Licensed to the Apache Software Foundation (ASF) under one
4  * or more contributor license agreements.  See the NOTICE file
5  * distributed with this work for additional information
6  * regarding copyright ownership.  The ASF licenses this file
7  * to you under the Apache License, Version 2.0 (the
8  * "License"); you may not use this file except in compliance
9  * with the License.  You may obtain a copy of the License at
10  *
11  *   http://www.apache.org/licenses/LICENSE-2.0
12  *
13  * Unless required by applicable law or agreed to in writing,
14  * software distributed under the License is distributed on an
15  * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
16  * KIND, either express or implied.  See the License for the
17  * specific language governing permissions and limitations
18  * under the License.
19  *
20  *************************************************************/
21 
22 
23 
24 #ifndef _CONNECTIVITY_DBASE_INDEXPAGE_HXX_
25 #define _CONNECTIVITY_DBASE_INDEXPAGE_HXX_
26 
27 //#ifndef _REF_HXX
28 //#include <tools/ref.hxx>
29 //#endif
30 #include <vos/ref.hxx>
31 #include <tools/stream.hxx>
32 #ifndef _VECTOR_
33 #include <vector>
34 #endif
35 //#ifndef _CONNECTIVITY_FILE_FCODE_HXX_
36 //#include "file/fcode.hxx"
37 //#endif
38 //#ifndef _CONNECTIVITY_DBASE_INDEXNODE_HXX_
39 //#include "dbase/dindexnode.hxx"
40 //#endif
41 
42 #if 0
43 namespace connectivity
44 {
45 	namespace dbase
46 	{
47 		//==================================================================
48 		// Index Seitenverweis
49 		//==================================================================
50 		//	SV_DECL_REF(ONDXPage); // Basisklasse da weitere Informationen gehalten werden muessen
51 
52 		class ONDXPage;
53 		typedef vos::ORef<ONDXPage>			ONDXPagePtr_BASE;
54 
55 		class ONDXPagePtr : public ONDXPagePtr_BASE //ONDXPageRef
56 		{
57 			friend  SvStream& operator << (SvStream &rStream, const ONDXPagePtr&);
58 			friend  SvStream& operator >> (SvStream &rStream, ONDXPagePtr&);
59 
60 			sal_uInt32	nPagePos;		// Position in der Indexdatei
61 
62 		public:
63 			ONDXPagePtr(sal_uInt32 nPos = 0):nPagePos(nPos){}
64 			ONDXPagePtr(const ONDXPagePtr& rRef);
65 			ONDXPagePtr(ONDXPage* pRefPage);
66 
67 			ONDXPagePtr& operator=(const ONDXPagePtr& rRef);
68 			ONDXPagePtr& operator=(ONDXPage* pPageRef);
69 
70 			sal_uInt32 GetPagePos() const {return nPagePos;}
71 			sal_Bool HasPage() const {return nPagePos != 0;}
72 			sal_Bool Is() const { return isValid(); }
73 			void Clear()
74 			{
75 				unbind();
76 			}
77 		};
78 
79 		SvStream& operator << (SvStream &rStream, const ONDXPagePtr&);
80 		SvStream& operator >> (SvStream &rStream, ONDXPagePtr&);
81 	}
82 }
83 #endif
84 #endif // _CONNECTIVITY_DBASE_INDEXPAGE_HXX_
85 
86