Docjar: A Java Source and Docuemnt Enginecom.*    java.*    javax.*    org.*    all    new    plug-in

Quick Search    Search Deep

com.eireneh.bible.control.search
Class Engine  view Engine download Engine.java

java.lang.Object
  extended bycom.eireneh.bible.control.search.Engine

public class Engine
extends java.lang.Object

The central interface to all searching. Functionality the I invisage includes:

Distribution Licence:
Project B is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License, version 2 as published by the Free Software Foundation.
This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.
The License is available on the internet here, by writing to Free Software Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA, Or locally at the Licence link below.
The copyright to this program is held by it's authors.


Field Summary
private  com.eireneh.bible.book.Bible bible
          The book to search
private  java.util.Hashtable commands
          The commands that we know about
private  java.util.Enumeration en
          While the answer is being worked out ...
private  java.util.Vector output
          The parsed version of the current string
 
Constructor Summary
Engine(com.eireneh.bible.book.Bible bible)
          Create a new search engine.
Engine(com.eireneh.bible.book.Bible bible, java.util.Hashtable commands)
          Create a new search engine.
 
Method Summary
 java.util.Enumeration elements()
          Most SearchWords (Almost all except the DefaultParamWord) need to access parameters, this method allows them access to the Engine's own Enumerator.
 com.eireneh.bible.book.Bible getBible()
          Accessor for the Bible to search.
 java.util.Hashtable getSearchHashtable()
          Accessor for the available SearchWords.
 java.util.Vector getSearchWords()
          Accessor for the whole array of SearchWords.
 com.eireneh.bible.passage.Passage search(com.eireneh.bible.passage.Passage ref, java.lang.String sought)
          Take a search string and decipher it into a Passage.
 com.eireneh.bible.passage.Passage search(com.eireneh.bible.passage.Passage ref, java.util.Vector output)
          Take a search string and decipher it into a Passage.
 com.eireneh.bible.passage.Passage search(java.lang.String sought)
          Take a search string and decipher it into a Passage.
 com.eireneh.bible.passage.Passage search(java.util.Vector output)
          Take a search string and decipher it into a Passage.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

bible

private com.eireneh.bible.book.Bible bible
The book to search


output

private java.util.Vector output
The parsed version of the current string


commands

private java.util.Hashtable commands
The commands that we know about


en

private java.util.Enumeration en
While the answer is being worked out ...

Constructor Detail

Engine

public Engine(com.eireneh.bible.book.Bible bible)
Create a new search engine. Bible should probably be Book however Book does not yet have a well defined interface.


Engine

public Engine(com.eireneh.bible.book.Bible bible,
              java.util.Hashtable commands)
Create a new search engine. Bible should probably be Book however Book does not yet have a well defined interface.

Method Detail

search

public com.eireneh.bible.passage.Passage search(com.eireneh.bible.passage.Passage ref,
                                                java.lang.String sought)
                                         throws SearchException
Take a search string and decipher it into a Passage.


search

public com.eireneh.bible.passage.Passage search(java.lang.String sought)
                                         throws SearchException
Take a search string and decipher it into a Passage.


search

public com.eireneh.bible.passage.Passage search(java.util.Vector output)
                                         throws SearchException
Take a search string and decipher it into a Passage.


search

public com.eireneh.bible.passage.Passage search(com.eireneh.bible.passage.Passage ref,
                                                java.util.Vector output)
                                         throws SearchException
Take a search string and decipher it into a Passage.


getBible

public com.eireneh.bible.book.Bible getBible()
Accessor for the Bible to search.


getSearchHashtable

public java.util.Hashtable getSearchHashtable()
Accessor for the available SearchWords. This is probably the same as from Options.getSearchHashtable() but just in case anyone has been playing around with it...


getSearchWords

public java.util.Vector getSearchWords()
Accessor for the whole array of SearchWords. I'm not sure why anyone would want this, but here it is anyway.


elements

public java.util.Enumeration elements()
Most SearchWords (Almost all except the DefaultParamWord) need to access parameters, this method allows them access to the Engine's own Enumerator. Use with care, and only if you are a SearchWord taking part in the current search.