public class BeanPropertyType<B> extends Object implements PropertyType<B>
| Constructor and Description |
|---|
BeanPropertyType(@NotNull TypeInformation beanType,
@NotNull Mapper mapper) |
| Modifier and Type | Method and Description |
|---|---|
B |
convert(@Nullable Object object,
@NotNull ConvertErrorRecorder errorRecorder)
Converts the given object (typically read from a property resource) to the given type, if possible.
|
static <B> @NotNull BeanPropertyType<B> |
of(@NotNull Class<B> type) |
static <B> @NotNull BeanPropertyType<B> |
of(@NotNull Class<B> type,
@NotNull Mapper mapper) |
@Nullable Object |
toExportValue(B value)
Converts the given value to its export value.
|
public BeanPropertyType(@NotNull
@NotNull TypeInformation beanType,
@NotNull
@NotNull Mapper mapper)
@NotNull public static <B> @NotNull BeanPropertyType<B> of(@NotNull @NotNull Class<B> type, @NotNull @NotNull Mapper mapper)
@NotNull public static <B> @NotNull BeanPropertyType<B> of(@NotNull @NotNull Class<B> type)
public B convert(@Nullable @Nullable Object object, @NotNull @NotNull ConvertErrorRecorder errorRecorder)
PropertyTypeconvert in interface PropertyType<B>object - the object to converterrorRecorder - error recorder to register errors even if a valid value is returned@Nullable public @Nullable Object toExportValue(@Nullable B value)
PropertyTypePropertyType.convert(java.lang.Object, ch.jalu.configme.properties.convertresult.ConvertErrorRecorder).)toExportValue in interface PropertyType<B>value - the value to convertCopyright © 2016–2023 The AuthMe Team. All rights reserved.