Package org.atmosphere.cpr
Class AtmosphereAnnotations
java.lang.Object
org.atmosphere.cpr.AtmosphereAnnotations
Single source of truth for all Atmosphere annotation types and their processor mappings.
All modules that need the list of core Atmosphere annotations should reference this
class rather than maintaining their own copy. The one exception is
AnnotationScanningServletContainerInitializer whose @HandlesTypes
annotation requires compile-time class literals and cannot delegate to a runtime list.
-
Method Summary
Modifier and TypeMethodDescriptionReturns the fully-qualified class names of all core Atmosphere annotations.static List<Class<? extends Annotation>> Returns the unmodifiable list of all core Atmosphere annotation types.static StringservicePath(Class<?> annotatedClass) Returns the path declared by the service annotation carried byannotatedClass, ornullwhen it carries none.
-
Method Details
-
coreAnnotations
Returns the unmodifiable list of all core Atmosphere annotation types.- Returns:
- the core annotations
-
servicePath
Returns the path declared by the service annotation carried byannotatedClass, ornullwhen it carries none.ManagedServiceandRoomServiceboth declare apath()that may hold a{template}segment, and both are registered through the sameAnnotatedProxywrapper and the same interceptor chain. Path resolution therefore has to treat them identically: testing for@ManagedServicealone silently skips a@RoomService, and every@PathParamfield on it injectsnull.- Parameters:
annotatedClass- the user class behind anAnnotatedProxy- Returns:
- the declared path, or
nullif the class carries no path-bearing service annotation
-
coreAnnotationNames
Returns the fully-qualified class names of all core Atmosphere annotations. Useful for modules that work with string-based annotation names (e.g. JandexDotName).- Returns:
- the core annotation names
-