Class MCRJerseyBaseFeature
java.lang.Object
org.mycore.frontend.jersey.feature.MCRJerseyBaseFeature
- All Implemented Interfaces:
jakarta.ws.rs.container.DynamicFeature
- Direct Known Subclasses:
MCRJerseyDefaultFeature
public abstract class MCRJerseyBaseFeature
extends Object
implements jakarta.ws.rs.container.DynamicFeature
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionprotected void
addFilter
(jakarta.ws.rs.core.FeatureContext context, MCRRestrictedAccess restrictedAccess) Register a MCRRestrictedAccess filter to the context.Returns a list of packages which will be used to scan for components.protected boolean
isStaticContent
(Class<?> resourceClass, Method resourceMethod) Checks if the class/method is annotated byMCRStaticContent
.Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface jakarta.ws.rs.container.DynamicFeature
configure
-
Constructor Details
-
MCRJerseyBaseFeature
public MCRJerseyBaseFeature()
-
-
Method Details
-
isStaticContent
Checks if the class/method is annotated byMCRStaticContent
.- Parameters:
resourceClass
- the class to checkresourceMethod
- the method to check- Returns:
- true if one of both is annotated as static
-
getPackages
Returns a list of packages which will be used to scan for components.- Returns:
- a list of java package names
-
addFilter
protected void addFilter(jakarta.ws.rs.core.FeatureContext context, MCRRestrictedAccess restrictedAccess) Register a MCRRestrictedAccess filter to the context.- Parameters:
context
- the context to add the restricted access toorestrictedAccess
- the restricted access
-