- Type Parameters:
WP
- The work piece which is being passed to the implementing interceptor and which is processed by the interceptor.
- All Superinterfaces:
Interceptor<WP,
WP>
- All Known Implementing Classes:
AssemblyInterceptorComposite
- Functional Interface:
- This is a functional interface and can therefore be used as the assignment target for a lambda expression or method reference.
A
AssemblyInterceptor
assembles a work piece object whilst the work
piece is passed to the next AssemblyInterceptor
in the assembly line
till all AssemblyInterceptor
in the assembly line were invoked.-
Method Summary
-
Method Details
-
intercept
This method is invoked with a work piece as argument. The method processes the work piece for the work piece to be passed to the succeedingAssemblyInterceptor
instance in order to finish the work piece. In case the interceptor is able to finish the the work piece then this is indicated by returning true. In case false is returned, then the work piece is considered not to be finished.- Specified by:
intercept
in interfaceInterceptor<WP,
WP> - Parameters:
aWorkPiece
- The work piece which is to be processed by theAssemblyInterceptor
instance.- Returns:
- The work piece as it was processed by the
AssemblyInterceptor
instance. The returned instance needs not to be the same instance as the one passed as method parameter: This way a decorator or a proxy may be returned, providing additional or tweaked functionality.
-