public class CharsetConverter extends AbstractBaseConverter<Charset>
String into a Charset.
For a description of the format, see Charset.forName(String).
Example:
@Parameter(names = { "--charset" }, converter = CharsetConverter.class)
private Charset charset;
Charset,
Charset.forName(String)failOnNull, targetClass| Constructor and Description |
|---|
CharsetConverter(String optionName)
Constructs a converter.
|
| Modifier and Type | Method and Description |
|---|---|
protected Charset |
convertImpl(String value)
Converts a value.
|
convert, getErrorString, isSingle, newParameterException, newParameterException, split, toInt, toURIpublic CharsetConverter(String optionName)
optionName - The option name, may be null.protected Charset convertImpl(String value)
AbstractBaseConverterconvertImpl in class AbstractBaseConverter<Charset>value - the value to convertCopyright © 2016-2016 Gary Gregory. All Rights Reserved.
Use is subject to The Apache Software License, Version 2.0