org.extex.resource.tool
Class TocIndex

java.lang.Object
  extended by org.extex.resource.tool.TocIndex

public class TocIndex
extends java.lang.Object

Traverse a directory tree and collect the files in an index.

Version:
$Revision: 7144 $
Author:
Gerd Neugebauer

Constructor Summary
TocIndex()
          Creates a new object.
 
Method Summary
static int commandLine(java.lang.String[] argv)
          The main program.
 long createIndex()
          Initialize the creation of the index and perform the creation itself.
static void main(java.lang.String[] args)
          Command line interface.
 void processCommandLine(java.lang.String[] argv)
          Process the list of string as command line parameters.
 void setBase(java.io.File base)
          Setter for base.
 void setOutFile(java.lang.String outFile)
          Setter for outFile.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

TocIndex

public TocIndex()
Creates a new object.

Method Detail

commandLine

public static int commandLine(java.lang.String[] argv)
The main program. The command line parameters are evaluated and the appropriate actions are performed. Exceptions are caught and reported to stderr.

Parameters:
argv - list of command line parameters
Returns:
the exit code

main

public static void main(java.lang.String[] args)
Command line interface.

Parameters:
args - the command line arguments

createIndex

public long createIndex()
                 throws java.lang.Exception
Initialize the creation of the index and perform the creation itself.

Returns:
the number of entries encountered
Throws:
java.lang.Exception - in case of an error

processCommandLine

public void processCommandLine(java.lang.String[] argv)
                        throws java.lang.Exception
Process the list of string as command line parameters.

Parameters:
argv - the command line parameters
Throws:
java.lang.Exception - in case of an error

setBase

public void setBase(java.io.File base)
Setter for base.

Parameters:
base - the base to set

setOutFile

public void setOutFile(java.lang.String outFile)
                throws java.lang.RuntimeException
Setter for outFile.

Parameters:
outFile - the outFile to set
Throws:
java.lang.RuntimeException - in case the argument is null