|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectorg.javalid.core.cache.AnnotationFieldCache
public class AnnotationFieldCache
Implementation cache for fields, storing all information about a field related to annotations.
| Constructor Summary | |
|---|---|
AnnotationFieldCache(JvGroup jvGroup,
java.lang.String fieldName)
|
|
| Method Summary | |
|---|---|
void |
addAnnotation(java.lang.annotation.Annotation annotation)
Add a new annotation for this field / method (must be an annotation supported by JaValid. |
java.lang.String |
createValidationPath(java.lang.String currentPath)
Returns a new path appended to currentPath, if currentPath is empty returns the name of the field / method only. |
java.util.List<java.lang.annotation.Annotation> |
getAnnotations()
Returns an immutable list with all annotations that are on the the field / method - supported by JaValid. |
JvGroup |
getJvGroup()
Returns the group annotation that was on the field, method or class. |
java.lang.String |
getName()
Returns name of field / method. |
NotEmpty |
getNotEmptyAnnotation()
If present, returns the NotEmpty annotation, else returns null. |
NotNull |
getNotNullAnnotation()
If present, returns the NotNull annotation, else returns null. |
StopValidation |
getStopValidationAnnotation()
If present, returns the StopValidation annotation else returns null. |
boolean |
hasAnnotations()
Returns true if at least one (javalid) supported annotation is present. |
boolean |
isAnnotationPresent(java.lang.Class<? extends java.lang.annotation.Annotation> annotation)
Returns true if given annotation is present in the map (at least once) |
java.lang.String |
toString()
|
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Constructor Detail |
|---|
public AnnotationFieldCache(JvGroup jvGroup,
java.lang.String fieldName)
| Method Detail |
|---|
public JvGroup getJvGroup()
AnnotationBaseCache
getJvGroup in interface AnnotationBaseCachepublic java.util.List<java.lang.annotation.Annotation> getAnnotations()
AnnotationBaseCache
getAnnotations in interface AnnotationBaseCachepublic void addAnnotation(java.lang.annotation.Annotation annotation)
AnnotationBaseCache
addAnnotation in interface AnnotationBaseCacheannotation - New annotationpublic boolean isAnnotationPresent(java.lang.Class<? extends java.lang.annotation.Annotation> annotation)
AnnotationBaseCache
isAnnotationPresent in interface AnnotationBaseCacheannotation - The annotation to check
public NotNull getNotNullAnnotation()
AnnotationCache
getNotNullAnnotation in interface AnnotationCachepublic NotEmpty getNotEmptyAnnotation()
AnnotationCache
getNotEmptyAnnotation in interface AnnotationCachepublic java.lang.String createValidationPath(java.lang.String currentPath)
AnnotationCache
createValidationPath in interface AnnotationCachecurrentPath - The current path to pre-pend
public StopValidation getStopValidationAnnotation()
AnnotationCache
getStopValidationAnnotation in interface AnnotationCachepublic java.lang.String getName()
AnnotationCache
getName in interface AnnotationCachepublic boolean hasAnnotations()
AnnotationBaseCache
hasAnnotations in interface AnnotationBaseCachepublic java.lang.String toString()
toString in class java.lang.Object
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||