接口 MultiValueConverter<S>
-
- 类型参数:
S- The source type
- 所有超级接口:
Comparable<Prioritized>,Prioritized
- 所有已知子接口:
StringToMultiValueConverter
- 所有已知实现类:
StringToArrayConverter,StringToBlockingDequeConverter,StringToBlockingQueueConverter,StringToCollectionConverter,StringToDequeConverter,StringToIterableConverter,StringToListConverter,StringToNavigableSetConverter,StringToQueueConverter,StringToSetConverter,StringToSortedSetConverter,StringToTransferQueueConverter
@SPI public interface MultiValueConverter<S> extends Prioritized
An interface to convert the source-typed value to multiple value, e.g , Java array,Collectionor sub-interfaces- 从以下版本开始:
- 2.7.6
-
-
字段概要
-
从接口继承的字段 org.apache.dubbo.common.lang.Prioritized
COMPARATOR, MAX_PRIORITY, MIN_PRIORITY, NORMAL_PRIORITY
-
-
方法概要
所有方法 静态方法 实例方法 抽象方法 默认方法 修饰符和类型 方法 说明 booleanaccept(Class<S> sourceType, Class<?> multiValueType)Accept the source type and target type or notObjectconvert(S source, Class<?> multiValueType, Class<?> elementType)Convert the source to be the multiple valuestatic <T> TconvertIfPossible(Object source, Class<?> multiValueType, Class<?> elementType)static MultiValueConverter<?>find(Class<?> sourceType, Class<?> targetType)Find theMultiValueConverterinstance fromExtensionLoaderwith the specified source and target typedefault Class<S>getSourceType()Get the source type-
从接口继承的方法 org.apache.dubbo.common.lang.Prioritized
compareTo, getPriority
-
-
-
-
方法详细资料
-
accept
boolean accept(Class<S> sourceType, Class<?> multiValueType)
Accept the source type and target type or not- 参数:
sourceType- the source typemultiValueType- the multi-value type- 返回:
- if accepted, return
true, orfalse
-
convert
Object convert(S source, Class<?> multiValueType, Class<?> elementType)
Convert the source to be the multiple value- 参数:
source- the source-typed valuemultiValueType- the multi-value typeelementType- the element type- 返回:
-
find
static MultiValueConverter<?> find(Class<?> sourceType, Class<?> targetType)
Find theMultiValueConverterinstance fromExtensionLoaderwith the specified source and target type- 参数:
sourceType- the source typetargetType- the target type- 返回:
nullif not found- 从以下版本开始:
- 2.7.8
- 另请参阅:
ExtensionLoader.getSupportedExtensionInstances()
-
-