Class Main.AbstractOptionHandler
java.lang.Object
org.apache.batik.apps.rasterizer.Main.AbstractOptionHandler
- All Implemented Interfaces:
Main.OptionHandler
- Direct Known Subclasses:
Main.NoValueOptionHandler, Main.SingleValueOptionHandler
- Enclosing class:
Main
public abstract static class Main.AbstractOptionHandler
extends Object
implements Main.OptionHandler
This abstract implementation of the
OptionHandler interface
throws an exception if the number of arguments passed to the
handleOption method does not match the number of expected
optionValues. If the size matches, the safeHandleOption
method is invoked.
Subclasses can implement the safeHandleOption method
assuming that the input array size is correct.- Version:
- $Id$
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidhandleOption(String[] optionValues, SVGConverter c) TheOptionHandlershould configure theSVGConverteraccording to the value of the option.abstract voidsafeHandleOption(String[] optionValues, SVGConverter c) Methods inherited from class Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface Main.OptionHandler
getOptionDescription, getOptionValuesLength
-
Constructor Details
-
AbstractOptionHandler
public AbstractOptionHandler()
-
-
Method Details
-
handleOption
Description copied from interface:Main.OptionHandlerTheOptionHandlershould configure theSVGConverteraccording to the value of the option. Should throw an IllegalArgumentException if optionValue is not an acceptable option.- Specified by:
handleOptionin interfaceMain.OptionHandler
-
safeHandleOption
-