@groovy.transform.CompileStatic class DefaultGraphQLInterceptorManager extends java.lang.Object implements GraphQLInterceptorManager, KeyClassQuery<java.util.List<GraphQLFetcherInterceptor>>
Default implementation of GraphQLInterceptorManager that will also return a result if the class requested is a subclass of a class that exists in the registry. All interceptors for the exact class searched and any parent classes will be returned. Multiple interceptors for the same class can be registered. Example: registerInterceptor(Collection, interceptor1) registerInterceptor(Collection, interceptor2) registerInterceptor(List, interceptor3) If an ArrayList is being intercepted, all 3 interceptors will fire The resulting list will be sorted based on order. Implement the Ordered trait to control the order of your interceptors.
| Modifiers | Name | Description |
|---|---|---|
protected java.util.Comparator |
interceptorComparator |
|
protected java.util.Map<java.lang.Class, java.util.List<GraphQLFetcherInterceptor>> |
interceptors |
|
protected java.util.List<GraphQLSchemaInterceptor> |
schemaInterceptors |
| Constructor and description |
|---|
DefaultGraphQLInterceptorManager() |
| Type Params | Return Type | Name and description |
|---|---|---|
|
java.util.List<GraphQLFetcherInterceptor> |
getInterceptors(java.lang.Class clazz) |
|
java.util.List<GraphQLSchemaInterceptor> |
getInterceptors() |
|
void |
registerInterceptor(java.lang.Class type, GraphQLFetcherInterceptor interceptor) |
|
void |
registerInterceptor(GraphQLSchemaInterceptor interceptor) |
| Methods inherited from class | Name |
|---|---|
class java.lang.Object |
java.lang.Object#equals(java.lang.Object), java.lang.Object#getClass(), java.lang.Object#hashCode(), java.lang.Object#notify(), java.lang.Object#notifyAll(), java.lang.Object#toString(), java.lang.Object#wait(), java.lang.Object#wait(long), java.lang.Object#wait(long, int) |