Package org.fisco.bcos.sdk.abi
Class Utils
java.lang.Object
org.fisco.bcos.sdk.abi.Utils
public class Utils
extends java.lang.Object
Utility functions.
-
Method Summary
Modifier and Type Method Description static java.util.List<TypeReference<Type>>
convert(java.util.List<TypeReference<?>> input)
static <T extends Type>
booleandynamicType(java.lang.reflect.Type type)
static <T extends Type>
java.lang.Class<T>getClassType(java.lang.reflect.Type type)
static int
getLength(java.util.List<Type> parameters)
static <T extends Type>
intgetOffset(java.lang.reflect.Type type)
static <T extends Type>
java.lang.StringgetTypeName(java.lang.reflect.Type type)
static <T extends Type>
java.lang.StringgetTypeName(TypeReference<T> typeReference)
static <T, R extends Type<T>, E extends Type<T>>
java.util.List<E>typeMap(java.util.List<java.util.List<T>> input, java.lang.Class<E> outerDestType, java.lang.Class<R> innerType)
static <T, R extends Type<T>>
java.util.List<R>typeMap(java.util.List<T> input, java.lang.Class<R> destType)
static java.util.List
typeMapWithoutGenericType(java.util.List input, java.lang.Class destType)
-
Method Details
-
getTypeName
-
getTypeName
-
dynamicType
public static <T extends Type> boolean dynamicType(java.lang.reflect.Type type) throws java.lang.ClassNotFoundException- Throws:
java.lang.ClassNotFoundException
-
getLength
-
getOffset
public static <T extends Type> int getOffset(java.lang.reflect.Type type) throws java.lang.ClassNotFoundException- Throws:
java.lang.ClassNotFoundException
-
getClassType
public static <T extends Type> java.lang.Class<T> getClassType(java.lang.reflect.Type type) throws java.lang.ClassNotFoundException- Throws:
java.lang.ClassNotFoundException
-
convert
-
typeMap
-
typeMap
public static <T, R extends Type<T>> java.util.List<R> typeMap(java.util.List<T> input, java.lang.Class<R> destType) throws TypeMappingException- Throws:
TypeMappingException
-
typeMapWithoutGenericType
public static java.util.List typeMapWithoutGenericType(java.util.List input, java.lang.Class destType) throws TypeMappingException- Throws:
TypeMappingException
-