You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@lucy.apache.org by nw...@apache.org on 2013/06/30 18:52:51 UTC
[lucy-commits] svn commit: r1498153 - in /lucy/site/trunk/content/docs/test: ./ Lucy.mdtext
Author: nwellnhof
Date: Sun Jun 30 16:52:51 2013
New Revision: 1498153
URL: http://svn.apache.org/r1498153
Log:
Test putting documentation in a .mdtext file
Added:
lucy/site/trunk/content/docs/test/
lucy/site/trunk/content/docs/test/Lucy.mdtext
Added: lucy/site/trunk/content/docs/test/Lucy.mdtext
URL: http://svn.apache.org/viewvc/lucy/site/trunk/content/docs/test/Lucy.mdtext?rev=1498153&view=auto
==============================================================================
--- lucy/site/trunk/content/docs/test/Lucy.mdtext (added)
+++ lucy/site/trunk/content/docs/test/Lucy.mdtext Sun Jun 30 16:52:51 2013
@@ -0,0 +1,208 @@
+Title: Apache Lucy Documentation - Lucy
+
+<div>
+<a name='___top' class='dummyTopAnchor' ></a>
+
+<h1><a class='u' href='#___top' title='click to go to top of document'
+name="NAME"
+>NAME</a></h1>
+
+<p>Lucy - Apache Lucy search engine library.</p>
+
+<h1><a class='u' href='#___top' title='click to go to top of document'
+name="VERSION"
+>VERSION</a></h1>
+
+<p>0.3.0</p>
+
+<h1><a class='u' href='#___top' title='click to go to top of document'
+name="SYNOPSIS"
+>SYNOPSIS</a></h1>
+
+<p>First,
+plan out your index structure,
+create the index,
+and add documents:</p>
+
+<pre> # indexer.pl
+
+ use Lucy::Index::Indexer;
+ use Lucy::Plan::Schema;
+ use Lucy::Analysis::EasyAnalyzer;
+ use Lucy::Plan::FullTextType;
+
+ # Create a Schema which defines index fields.
+ my $schema = Lucy::Plan::Schema->new;
+ my $easyanalyzer = Lucy::Analysis::EasyAnalyzer->new(
+ language => 'en',
+ );
+ my $type = Lucy::Plan::FullTextType->new(
+ analyzer => $easyanalyzer,
+ );
+ $schema->spec_field( name => 'title', type => $type );
+ $schema->spec_field( name => 'content', type => $type );
+
+ # Create the index and add documents.
+ my $indexer = Lucy::Index::Indexer->new(
+ schema => $schema,
+ index => '/path/to/index',
+ create => 1,
+ );
+ while ( my ( $title, $content ) = each %source_docs ) {
+ $indexer->add_doc({
+ title => $title,
+ content => $content,
+ });
+ }
+ $indexer->commit;</pre>
+
+<p>Then, search the index:</p>
+
+<pre> # search.pl
+
+ use Lucy::Search::IndexSearcher;
+
+ my $searcher = Lucy::Search::IndexSearcher->new(
+ index => '/path/to/index'
+ );
+ my $hits = $searcher->hits( query => "foo bar" );
+ while ( my $hit = $hits->next ) {
+ print "$hit->{title}\n";
+ }</pre>
+
+<h1><a class='u' href='#___top' title='click to go to top of document'
+name="DESCRIPTION"
+>DESCRIPTION</a></h1>
+
+<p>The Apache Lucy search engine library delivers high-performance, modular full-text search.</p>
+
+<h2><a class='u' href='#___top' title='click to go to top of document'
+name="Features"
+>Features</a></h2>
+
+<ul>
+<li>Extremely fast. A single machine can handle millions of documents.</li>
+
+<li>Scalable to multiple machines.</li>
+
+<li>Incremental indexing (addition/deletion of documents to/from an existing index).</li>
+
+<li>Configurable near-real-time index updates.</li>
+
+<li>Unicode support.</li>
+
+<li>Support for boolean operators AND, OR, and AND NOT; parenthetical groupings; prepended +plus and -minus.</li>
+
+<li>Algorithmic selection of relevant excerpts and highlighting of search terms within excerpts.</li>
+
+<li>Highly customizable query and indexing APIs.</li>
+
+<li>Customizable sorting.</li>
+
+<li>Phrase matching.</li>
+
+<li>Stemming.</li>
+
+<li>Stoplists.</li>
+</ul>
+
+<h2><a class='u' href='#___top' title='click to go to top of document'
+name="Getting_Started"
+>Getting Started</a></h2>
+
+<p><a href="http://search.cpan.org/perldoc?Lucy%3A%3ASimple" class="podlinkpod"
+>Lucy::Simple</a> provides a stripped down API which may suffice for many tasks.</p>
+
+<p><a href="http://search.cpan.org/perldoc?Lucy%3A%3ADocs%3A%3ATutorial" class="podlinkpod"
+>Lucy::Docs::Tutorial</a> demonstrates how to build a basic CGI search application.</p>
+
+<p>The tutorial spends most of its time on these five classes:</p>
+
+<ul>
+<li><a href="http://search.cpan.org/perldoc?Lucy%3A%3APlan%3A%3ASchema" class="podlinkpod"
+>Lucy::Plan::Schema</a> - Plan out your index.</li>
+
+<li><a href="http://search.cpan.org/perldoc?Lucy%3A%3APlan%3A%3AFieldType" class="podlinkpod"
+>Lucy::Plan::FieldType</a> - Define index fields.</li>
+
+<li><a href="http://search.cpan.org/perldoc?Lucy%3A%3AIndex%3A%3AIndexer" class="podlinkpod"
+>Lucy::Index::Indexer</a> - Manipulate index content.</li>
+
+<li><a href="http://search.cpan.org/perldoc?Lucy%3A%3ASearch%3A%3AIndexSearcher" class="podlinkpod"
+>Lucy::Search::IndexSearcher</a> - Search an index.</li>
+
+<li><a href="http://search.cpan.org/perldoc?Lucy%3A%3AAnalysis%3A%3AEasyAnalyzer" class="podlinkpod"
+>Lucy::Analysis::EasyAnalyzer</a> - A one-size-fits-all parser/tokenizer.</li>
+</ul>
+
+<h2><a class='u' href='#___top' title='click to go to top of document'
+name="Delving_Deeper"
+>Delving Deeper</a></h2>
+
+<p><a href="http://search.cpan.org/perldoc?Lucy%3A%3ADocs%3A%3ACookbook" class="podlinkpod"
+>Lucy::Docs::Cookbook</a> augments the tutorial with more advanced recipes.</p>
+
+<p>For creating complex queries, see <a href="http://search.cpan.org/perldoc?Lucy%3A%3ASearch%3A%3AQuery" class="podlinkpod"
+>Lucy::Search::Query</a> and its subclasses <a href="http://search.cpan.org/perldoc?Lucy%3A%3ASearch%3A%3ATermQuery" class="podlinkpod"
+>TermQuery</a>, <a href="http://search.cpan.org/perldoc?Lucy%3A%3ASearch%3A%3APhraseQuery" class="podlinkpod"
+>PhraseQuery</a>, <a href="http://search.cpan.org/perldoc?Lucy%3A%3ASearch%3A%3AANDQuery" class="podlinkpod"
+>ANDQuery</a>, <a href="http://search.cpan.org/perldoc?Lucy%3A%3ASearch%3A%3AORQuery" class="podlinkpod"
+>ORQuery</a>, <a href="http://search.cpan.org/perldoc?Lucy%3A%3ASearch%3A%3ANOTQuery" class="podlinkpod"
+>NOTQuery</a>, <a href="http://search.cpan.org/perldoc?Lucy%3A%3ASearch%3A%3ARequiredOptionalQuery" class="podlinkpod"
+>RequiredOptionalQuery</a>, <a href="http://search.cpan.org/perldoc?Lucy%3A%3ASearch%3A%3AMatchAllQuery" class="podlinkpod"
+>MatchAllQuery</a>, and <a href="http://search.cpan.org/perldoc?Lucy%3A%3ASearch%3A%3ANoMatchQuery" class="podlinkpod"
+>NoMatchQuery</a>, plus <a href="http://search.cpan.org/perldoc?Lucy%3A%3ASearch%3A%3AQueryParser" class="podlinkpod"
+>Lucy::Search::QueryParser</a>.</p>
+
+<p>For distributed searching, see <a href="http://search.cpan.org/perldoc?LucyX%3A%3ARemote%3A%3ASearchServer" class="podlinkpod"
+>LucyX::Remote::SearchServer</a>, <a href="http://search.cpan.org/perldoc?LucyX%3A%3ARemote%3A%3ASearchClient" class="podlinkpod"
+>LucyX::Remote::SearchClient</a>, and <a href="http://search.cpan.org/perldoc?LucyX%3A%3ARemote%3A%3AClusterSearcher" class="podlinkpod"
+>LucyX::Remote::ClusterSearcher</a>.</p>
+
+<h2><a class='u' href='#___top' title='click to go to top of document'
+name="Backwards_Compatibility_Policy"
+>Backwards Compatibility Policy</a></h2>
+
+<p>Lucy will spin off stable forks into new namespaces periodically. The first will be named "Lucy1". Users who require strong backwards compatibility should use a stable fork.</p>
+
+<p>The main namespace, "Lucy", is an API-unstable development branch (as hinted at by its 0.x.x version number). Superficial interface changes happen frequently. Hard file format compatibility breaks which require reindexing are rare, as we generally try to provide continuity across multiple releases, but we reserve the right to make such changes.</p>
+
+<h1><a class='u' href='#___top' title='click to go to top of document'
+name="CLASS_METHODS"
+>CLASS METHODS</a></h1>
+
+<p>The Lucy module itself does not have a large interface, providing only a single public class method.</p>
+
+<h2><a class='u' href='#___top' title='click to go to top of document'
+name="error"
+>error</a></h2>
+
+<pre> my $instream = $folder->open_in( file => 'foo' ) or die Clownfish->error;</pre>
+
+<p>Access a shared variable which is set by some routines on failure. It will always be either a <a href="http://search.cpan.org/perldoc?Clownfish%3A%3AErr" class="podlinkpod"
+>Clownfish::Err</a> object or undef.</p>
+
+<h1><a class='u' href='#___top' title='click to go to top of document'
+name="SUPPORT"
+>SUPPORT</a></h1>
+
+<p>The Apache Lucy homepage, where you'll find links to our mailing lists and so on, is <a href="http://lucy.apache.org" class="podlinkurl"
+>http://lucy.apache.org</a>. Please direct support questions to the Lucy users mailing list.</p>
+
+<h1><a class='u' href='#___top' title='click to go to top of document'
+name="BUGS"
+>BUGS</a></h1>
+
+<p>Not thread-safe.</p>
+
+<p>Some exceptions leak memory.</p>
+
+<p>If you find a bug, please inquire on the Lucy users mailing list about it, then report it on the Lucy issue tracker once it has been confirmed: <a href="https://issues.apache.org/jira/browse/LUCY" class="podlinkurl"
+>https://issues.apache.org/jira/browse/LUCY</a>.</p>
+
+<h1><a class='u' href='#___top' title='click to go to top of document'
+name="COPYRIGHT"
+>COPYRIGHT</a></h1>
+
+<p>Apache Lucy is distributed under the Apache License, Version 2.0, as described in the file <code>LICENSE</code> included with the distribution.</p>
+</div>