Class AnnotationConvertUtil
- java.lang.Object
-
- com.github.toolarium.enumeration.configuration.util.AnnotationConvertUtil
-
public final class AnnotationConvertUtil extends java.lang.Object
Annotation convert utility
-
-
Field Summary
Fields Modifier and Type Field Description static java.time.Instant
MAX_TIMESTAMP
static java.lang.String
MAX_TIMESTAMP_STRING
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description static AnnotationConvertUtil
getInstance()
Get the instance<T extends javax.lang.model.element.ExecutableElement>
java.lang.StringgetName(T type)
Get the name<T extends javax.lang.model.element.AnnotationValue>
java.lang.StringgetValue(T type)
Get the namejava.time.Instant
parseDate(java.lang.String input)
Parse a datejava.lang.String
trimQuotationMarks(java.lang.String input)
Trim quotation marks
-
-
-
Field Detail
-
MAX_TIMESTAMP_STRING
public static final java.lang.String MAX_TIMESTAMP_STRING
- See Also:
- Constant Field Values
-
MAX_TIMESTAMP
public static final java.time.Instant MAX_TIMESTAMP
-
-
Method Detail
-
getInstance
public static AnnotationConvertUtil getInstance()
Get the instance- Returns:
- the instance
-
parseDate
public java.time.Instant parseDate(java.lang.String input)
Parse a date- Parameters:
input
- the input date as string- Returns:
- the Instant
-
getName
public <T extends javax.lang.model.element.ExecutableElement> java.lang.String getName(T type)
Get the name- Type Parameters:
T
- the generic type- Parameters:
type
- the type- Returns:
- the type as name
-
getValue
public <T extends javax.lang.model.element.AnnotationValue> java.lang.String getValue(T type)
Get the name- Type Parameters:
T
- the generic type- Parameters:
type
- the type- Returns:
- the type as name
-
trimQuotationMarks
public java.lang.String trimQuotationMarks(java.lang.String input)
Trim quotation marks- Parameters:
input
- the input- Returns:
- the trimmed output
-
-