Class RepresentationModelProcessorInvoker
java.lang.Object
org.springframework.hateoas.server.mvc.RepresentationModelProcessorInvoker
Component to easily invoke all
RepresentationModelProcessor instances registered for values of type
RepresentationModel.- Since:
- 0.20
- Author:
- Oliver Gierke, Greg Turnquist
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic classRepresentationModelProcessorInvoker.ProcessorWrapperforRepresentationModelProcessors targetingCollectionModel. -
Constructor Summary
ConstructorsConstructorDescriptionCreates a newRepresentationModelProcessorInvokerto consider the givenRepresentationModelProcessorto post-process the controller methods return value to before invoking the delegate. -
Method Summary
Modifier and TypeMethodDescription<T extends RepresentationModel<T>>
TinvokeProcessorsFor(T value) Invokes allRepresentationModelProcessorinstances registered for the type of the given value.<T extends RepresentationModel<T>>
TinvokeProcessorsFor(T value, ResolvableType referenceType) Invokes allRepresentationModelProcessorinstances registered for the type of the given value and reference type.
-
Constructor Details
-
RepresentationModelProcessorInvoker
Creates a newRepresentationModelProcessorInvokerto consider the givenRepresentationModelProcessorto post-process the controller methods return value to before invoking the delegate.- Parameters:
processors- theRepresentationModelProcessors to be considered, must not be null.
-
-
Method Details
-
invokeProcessorsFor
Invokes allRepresentationModelProcessorinstances registered for the type of the given value.- Parameters:
value- must not be null.- Returns:
-
invokeProcessorsFor
public <T extends RepresentationModel<T>> T invokeProcessorsFor(T value, ResolvableType referenceType) Invokes allRepresentationModelProcessorinstances registered for the type of the given value and reference type.- Parameters:
value- must not be null.referenceType- must not be null.- Returns:
-