public enum MappingType extends Enum<MappingType>
cn.crane4j.core.container.MethodInvokerContainer;,
ContainerMethod.type()| 枚举常量和说明 |
|---|
MAPPED
The return value of the method is already a
Map set grouped by the key value. |
NONE
Instead of mapping by key,
combine key and value directly into a Map collection in sequence,
such as
Collections#zip. |
ONE_TO_MANY
One key corresponds to multiple data source objects,
that is, one data source object only corresponds
to the same key value in the returned data source object collection.
|
ONE_TO_ONE
One key corresponds to one data source object, that is,
in the returned data source object collection,
multiple data source objects correspond to the same key value.
|
public static final MappingType NONE
Instead of mapping by key,
combine key and value directly into a Map collection in sequence,
such as Collections#zip.
When using this type,
the return ContainerMethod.resultKey() and ContainerMethod.resultType() are ignored.
2.4.0public static final MappingType MAPPED
The return value of the method is already a Map set grouped by the key value.
No further conversion is required according to the key value.
When using this type,
the return ContainerMethod.resultKey() and ContainerMethod.resultType() are ignored.
public static final MappingType ONE_TO_ONE
One key corresponds to one data source object, that is, in the returned data source object collection, multiple data source objects correspond to the same key value.
When using this type,
the type which specified by ContainerMethod.resultType() must be Map or java bean.
public static final MappingType ONE_TO_MANY
One key corresponds to multiple data source objects, that is, one data source object only corresponds to the same key value in the returned data source object collection.
When using this type,
the type which specified by ContainerMethod.resultType() must be Map or java bean.
public static MappingType[] values()
for (MappingType c : MappingType.values()) System.out.println(c);
public static MappingType valueOf(String name)
name - 要返回的枚举常量的名称。IllegalArgumentException - 如果该枚举类型没有带有指定名称的常量NullPointerException - 如果参数为空值Copyright © 2024. All rights reserved.