Package org.kohsuke.args4j.spi

## Class PathOptionHandler

- java.lang.Object
- - org.kohsuke.args4j.spi.OptionHandler<T>
  - - org.kohsuke.args4j.spi.OneArgumentOptionHandler<java.nio.file.Path>
    - - org.kohsuke.args4j.spi.PathOptionHandler

    public class PathOptionHandler
    extends OneArgumentOptionHandler<java.nio.file.Path>

Takes a single argument to the option and maps that to `Path`.

Author:
  kmahoney

### Field Summary

### Fields inherited from class org.kohsuke.args4j.spi.OptionHandler

`option, owner, setter`

### Constructor Summary

Constructors
`PathOptionHandler​(CmdLineParser parser, OptionDef option, Setter<? super java.nio.file.Path> setter)`

### Method Summary

All Methods Instance Methods Concrete Methods
`java.lang.String` `getDefaultMetaVariable()` Gets the default meta variable name used to print the usage screen.
`protected java.nio.file.Path` `parse​(java.lang.String argument)` Parses a string to a real value of Type <T>.

### Methods inherited from class org.kohsuke.args4j.spi.OneArgumentOptionHandler

`parseArguments`

### Methods inherited from class org.kohsuke.args4j.spi.OptionHandler

`getMetaVariable, getNameAndMeta, getNameAndMeta, print, printDefaultValue`

### Methods inherited from class java.lang.Object

`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

### Constructor Detail

#### PathOptionHandler

    public PathOptionHandler​(CmdLineParser parser,
                             OptionDef option,
                             Setter<? super java.nio.file.Path> setter)

### Method Detail

#### parse

    protected java.nio.file.Path parse​(java.lang.String argument)
                                throws java.lang.NumberFormatException,
                                       CmdLineException

Description copied from class: `OneArgumentOptionHandler`
Parses a string to a real value of Type <T>.

Specified by:
  `parse` in class `OneArgumentOptionHandler<java.nio.file.Path>`
Parameters:
  `argument` - String value to parse
Returns:
  the parsed value
Throws:
  `java.lang.NumberFormatException` - if parsing is not possible
  `CmdLineException` - if the parsing encounters a failure that should be reported to the user.

#### getDefaultMetaVariable

    public java.lang.String getDefaultMetaVariable()

Description copied from class: `OptionHandler`
Gets the default meta variable name used to print the usage screen. The value returned by this method can be a reference in the `ResourceBundle`, if one was passed to `CmdLineParser`.

Overrides:
  `getDefaultMetaVariable` in class `OneArgumentOptionHandler<java.nio.file.Path>`
Returns:
  `null` to hide a meta variable.