public class CoderUtils extends Object
Constructor and Description |
---|
CoderUtils() |
Modifier and Type | Method and Description |
---|---|
static byte[] |
ASN1StringToBuffer(Object obj,
ElementInfo elementInfo) |
static String |
bufferToASN1String(byte[] byteBuf,
ElementInfo elementInfo) |
static void |
checkConstraints(long value,
ElementInfo elementInfo) |
static void |
checkForOptionalField(Field field,
ElementInfo elementInfo) |
static BitString |
defStringToOctetString(String bhString) |
static Method |
findDoSelectMethodForField(Field field,
Class<?> objectClass,
Class<?> paramClass) |
static Method |
findGetterMethodForField(Field field,
Class<?> objectClass) |
static Method |
findIsSelectedMethodForField(Field field,
Class<?> objectClass) |
static Method |
findMethodForField(String methodName,
Class<?> objectClass,
Class<?> paramClass) |
static Method |
findSetterMethodForField(Field field,
Class<?> objectClass,
Class<?> paramClass) |
static Class<?> |
getCollectionType(ElementInfo elementInfo) |
static Class<?> |
getCollectionType(ParameterizedType tp) |
static int |
getIntegerLength(int value) |
static int |
getIntegerLength(long value) |
static int |
getPositiveIntegerLength(int value) |
static int |
getPositiveIntegerLength(long value) |
static SortedMap<Integer,Field> |
getSetOrder(Class<?> objectClass) |
static int |
getStringTagForElement(ElementInfo elementInfo) |
static boolean |
isAnyField(Field field,
ElementInfo elementInfo) |
static boolean |
isMemberClass(Class<?> objectClass,
ElementInfo elementInfo) |
static boolean |
isNullField(Field field,
ElementInfo elementInfo) |
static boolean |
isOptional(ElementInfo elementInfo) |
static boolean |
isOptionalField(Field field,
ElementInfo elementInfo) |
static boolean |
isSequenceSet(ElementInfo elementInfo) |
static boolean |
isSequenceSetOf(ElementInfo elementInfo) |
public static int getIntegerLength(int value)
public static int getIntegerLength(long value)
public static int getPositiveIntegerLength(int value)
public static int getPositiveIntegerLength(long value)
public static int getStringTagForElement(ElementInfo elementInfo)
public static void checkConstraints(long value, ElementInfo elementInfo) throws Exception
Exception
public static boolean isAnyField(Field field, ElementInfo elementInfo)
public static boolean isNullField(Field field, ElementInfo elementInfo)
public static boolean isOptionalField(Field field, ElementInfo elementInfo)
public static boolean isOptional(ElementInfo elementInfo)
public static void checkForOptionalField(Field field, ElementInfo elementInfo) throws Exception
Exception
public static boolean isSequenceSet(ElementInfo elementInfo)
public static boolean isSequenceSetOf(ElementInfo elementInfo)
public static Method findMethodForField(String methodName, Class<?> objectClass, Class<?> paramClass) throws NoSuchMethodException
NoSuchMethodException
public static Method findSetterMethodForField(Field field, Class<?> objectClass, Class<?> paramClass) throws NoSuchMethodException
NoSuchMethodException
public static Method findDoSelectMethodForField(Field field, Class<?> objectClass, Class<?> paramClass) throws NoSuchMethodException
NoSuchMethodException
public static Method findGetterMethodForField(Field field, Class<?> objectClass) throws NoSuchMethodException
NoSuchMethodException
public static Method findIsSelectedMethodForField(Field field, Class<?> objectClass) throws NoSuchMethodException
NoSuchMethodException
public static boolean isMemberClass(Class<?> objectClass, ElementInfo elementInfo)
public static byte[] ASN1StringToBuffer(Object obj, ElementInfo elementInfo) throws UnsupportedEncodingException
UnsupportedEncodingException
public static String bufferToASN1String(byte[] byteBuf, ElementInfo elementInfo) throws UnsupportedEncodingException
UnsupportedEncodingException
public static Class<?> getCollectionType(ElementInfo elementInfo)
public static Class<?> getCollectionType(ParameterizedType tp)
Copyright © 2015 universAAL Consortium. All Rights Reserved.