1<!-- 2 Licensed to the Apache Software Foundation (ASF) under one or more 3 contributor license agreements. See the NOTICE file distributed with 4 this work for additional information regarding copyright ownership. 5 The ASF licenses this file to You under the Apache License, Version 2.0 6 (the "License"); you may not use this file except in compliance with 7 the License. You may obtain a copy of the License at 8 9 http://www.apache.org/licenses/LICENSE-2.0 10 11 Unless required by applicable law or agreed to in writing, software 12 distributed under the License is distributed on an "AS IS" BASIS, 13 WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 14 See the License for the specific language governing permissions and 15 limitations under the License. 16--> 17<html> 18 <head> 19 <title>Apache Lucene Spatial-Extras Module</title> 20 </head> 21 <body> 22 23 <h1>The Spatial-Extras Module for Apache Lucene</h1> 24 25 <p> 26 The spatial-extras module, new to Lucene 6.5, is the new home for the original 27 lucene spatial module. 28 The principle interface to this module is a {@link org.apache.lucene.spatial.SpatialStrategy} 29 which encapsulates an approach to indexing and searching 30 based on shapes. Different Strategies have different features and 31 performance profiles, which are documented at each Strategy implementation 32 class level. 33 </p> 34 <p> 35 For some sample code showing how to use the API, see 36 SpatialExample.java in the tests. 37 </p> 38<p> 39 The spatial-extras module uses 40 <a href="https://github.com/spatial4j/spatial4j">Spatial4j</a> 41 heavily. Spatial4j is an ASL licensed library with these capabilities: 42 <ul> 43 <li>Provides shape implementations, namely point, rectangle, 44 and circle. Both geospatial contexts and plain 2D Euclidean/Cartesian contexts 45 are supported. 46 With an additional dependency, it adds polygon and other geometry shape 47 support via integration with 48 <a href="http://sourceforge.net/projects/jts-topo-suite/">JTS Topology Suite</a>. 49 This includes dateline wrap support.</li> 50 <li>Shape parsing and serialization, including 51 <a href="http://en.wikipedia.org/wiki/Well-known_text">Well-Known Text (WKT)</a> 52 (via JTS).</li> 53 <li>Distance and other spatial related math calculations.</li> 54 </ul> 55 <p> 56 Historical note: The new spatial-extras module was once known as 57 Lucene Spatial Playground (LSP) as an external project. In ~March 2012, LSP 58 split into the spatial module as part of Lucene and Spatial4j externally. A 59 large chunk of the LSP implementation originated as SOLR-2155 which uses 60 trie/prefix-tree algorithms with a geohash encoding. That approach is 61 implemented in {@link org.apache.lucene.spatial.prefix.RecursivePrefixTreeStrategy} 62 today. 63 </p> 64 65 </body> 66</html> 67