• Main Page
  • Related Pages
  • Namespaces
  • Classes
  • Files
  • File List

Key.h

00001 /**********************************************************************
00002  * $Id: Key.h 2556 2009-06-06 22:22:28Z strk $
00003  *
00004  * GEOS - Geometry Engine Open Source
00005  * http://geos.refractions.net
00006  *
00007  * Copyright (C) 2006 Refractions Research Inc.
00008  *
00009  * This is free software; you can redistribute and/or modify it under
00010  * the terms of the GNU Lesser General Public Licence as published
00011  * by the Free Software Foundation. 
00012  * See the COPYING file for more information.
00013  *
00014  **********************************************************************/
00015 
00016 #ifndef GEOS_IDX_BINTREE_KEY_H
00017 #define GEOS_IDX_BINTREE_KEY_H
00018 
00019 #include <geos/export.h>
00020 
00021 // Forward declarations
00022 namespace geos {
00023         namespace index { 
00024                 namespace bintree { 
00025                         class Interval;
00026                 }
00027         }
00028 }
00029 
00030 namespace geos {
00031 namespace index { // geos::index
00032 namespace bintree { // geos::index::bintree
00033 
00040 class GEOS_DLL Key {
00041 
00042 public:
00043 
00044         static int computeLevel(Interval *newInterval);
00045 
00046         Key(Interval *newInterval);
00047 
00048         ~Key();
00049 
00050         double getPoint();
00051 
00052         int getLevel();
00053 
00054         Interval* getInterval();
00055 
00056         void computeKey(Interval *itemInterval);
00057 
00058 private:
00059 
00060         // the fields which make up the key
00061         double pt;
00062         int level;
00063 
00064         // auxiliary data which is derived from the key for use in computation
00065         Interval *interval;
00066 
00067         void computeInterval(int level, Interval *itemInterval);
00068 };
00069 
00070 } // namespace geos::index::bintree
00071 } // namespace geos::index
00072 } // namespace geos
00073 
00074 #endif // GEOS_IDX_BINTREE_KEY_H
00075 
00076 /**********************************************************************
00077  * $Log$
00078  * Revision 1.1  2006/03/22 16:01:33  strk
00079  * indexBintree.h header split, classes renamed to match JTS
00080  *
00081  **********************************************************************/
00082 

Generated on Thu Jul 22 2010 for GEOS by  doxygen 1.7.1