DefaultArgumentConverter is the default implementation of the
ArgumentConverter API.
The DefaultArgumentConverter is able to convert from strings to a
number of primitive types and their corresponding wrapper types (Byte, Short,
Integer, Long, Float, and Double), date and time types from the
java.time package, and some additional common Java types such as
File, BigDecimal, BigInteger, Currency,
Locale, URI, URL, UUID, etc.
If the source and target types are identical the source object will not be modified.
org.junit.jupiter.params.converter.ArgumentConverter , org.junit.platform.commons.support.conversion.ConversionSupport
| Modifier and Type | Field and Description |
|---|---|
| public static final DefaultArgumentConverter |
| Access | Constructor and Description |
|---|---|
| private |
| Modifier and Type | Method and Description |
|---|---|
| public final @Nullable Object | |
| public final @Nullable Object | |
| public final @Nullable Object | |
| pack-priv @Nullable Object |
| INSTANCE | back to summary |
|---|---|
| public static final DefaultArgumentConverter INSTANCE | |
| DefaultArgumentConverter | back to summary |
|---|---|
| private DefaultArgumentConverter() | |
| convert | back to summary |
|---|---|
public final @Nullable Object convert(@Nullable Object source, ParameterContext context)
| |
| convert | back to summary |
|---|---|
public final @Nullable Object convert(@Nullable Object source, FieldContext context) throws ArgumentConversionException
| |
| convert | back to summary |
|---|---|
| public final @Nullable Object convert(@Nullable Object source, Class<?> targetType, ClassLoader classLoader) | |
| convert | back to summary |
|---|---|
| pack-priv @Nullable Object convert(@Nullable String source, Class<?> targetType, ClassLoader classLoader) | |