1 /*************************************************************************
3 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
5 * Copyright 2008 by Sun Microsystems, Inc.
7 * OpenOffice.org - a multi-platform office productivity suite
9 * $RCSfile: DIndexPage.hxx,v $
12 * This file is part of OpenOffice.org.
14 * OpenOffice.org is free software: you can redistribute it and/or modify
15 * it under the terms of the GNU Lesser General Public License version 3
16 * only, as published by the Free Software Foundation.
18 * OpenOffice.org is distributed in the hope that it will be useful,
19 * but WITHOUT ANY WARRANTY; without even the implied warranty of
20 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
21 * GNU Lesser General Public License version 3 for more details
22 * (a copy is included in the LICENSE file that accompanied this code).
24 * You should have received a copy of the GNU Lesser General Public License
25 * version 3 along with OpenOffice.org. If not, see
26 * <http://www.openoffice.org/license.html>
27 * for a copy of the LGPLv3 License.
29 ************************************************************************/
31 #ifndef _CONNECTIVITY_DBASE_INDEXPAGE_HXX_
32 #define _CONNECTIVITY_DBASE_INDEXPAGE_HXX_
35 //#include <tools/ref.hxx>
37 #include <vos/ref.hxx>
38 #include <tools/stream.hxx>
42 //#ifndef _CONNECTIVITY_FILE_FCODE_HXX_
43 //#include "file/fcode.hxx"
45 //#ifndef _CONNECTIVITY_DBASE_INDEXNODE_HXX_
46 //#include "dbase/dindexnode.hxx"
50 namespace connectivity
54 //==================================================================
55 // Index Seitenverweis
56 //==================================================================
57 // SV_DECL_REF(ONDXPage); // Basisklasse da weitere Informationen gehalten werden muessen
60 typedef vos::ORef
<ONDXPage
> ONDXPagePtr_BASE
;
62 class ONDXPagePtr
: public ONDXPagePtr_BASE
//ONDXPageRef
64 friend SvStream
& operator << (SvStream
&rStream
, const ONDXPagePtr
&);
65 friend SvStream
& operator >> (SvStream
&rStream
, ONDXPagePtr
&);
67 UINT32 nPagePos
; // Position in der Indexdatei
70 ONDXPagePtr(UINT32 nPos
= 0):nPagePos(nPos
){}
71 ONDXPagePtr(const ONDXPagePtr
& rRef
);
72 ONDXPagePtr(ONDXPage
* pRefPage
);
74 ONDXPagePtr
& operator=(const ONDXPagePtr
& rRef
);
75 ONDXPagePtr
& operator=(ONDXPage
* pPageRef
);
77 UINT32
GetPagePos() const {return nPagePos
;}
78 BOOL
HasPage() const {return nPagePos
!= 0;}
79 sal_Bool
Is() const { return isValid(); }
86 SvStream
& operator << (SvStream
&rStream
, const ONDXPagePtr
&);
87 SvStream
& operator >> (SvStream
&rStream
, ONDXPagePtr
&);
91 #endif // _CONNECTIVITY_DBASE_INDEXPAGE_HXX_