Interface Parser<T>

Type Parameters:
T - The base class this parser can parse all subtypes of.
All Known Implementing Classes:
AmountParser, BooleanParser, ByteParser, CharacterParser, ClassParser, DateParser, DoubleParser, DurationParser, EnumParser, FileParser, FloatParser, InetSocketAddressParser, IntegerParser, ListParser, LongParser, MapParser, NonParameterizedTypeParser, NumberParser, PairParser, RangeParser, SetParser, ShortParser, StringParser, TimeDurationParser, TypeParameterizedParser, UnitParser, URIParser, URLParser

public interface Parser<T>

An interface to a command line argument parser.

Method Summary
 T parse(ParserOracle parserOracle, Type type, String raw)
          Parses strings as arguments of a given subtype of T.

Method Detail


T parse(ParserOracle parserOracle,
        Type type,
        String raw)
        throws IllegalArgumentException
Parses strings as arguments of a given subtype of T.

parserOracle - The registered parserOracle for delegation.
type - The target type of the parsed argument.
raw - The raw value of the argument.
A value of the given type parsed from the raw value.
IllegalArgumentException - if the raw value could not be parsed into a value of the given type.