Interface ProcessorHandler
public interface ProcessorHandler
Processor handler that can handle and apply stitch processor,
in other words it is responsible for stitch transformation.
-
Method Summary
Modifier and TypeMethodDescriptionReturns file parameter name for external file.com.fasterxml.jackson.databind.JsonNodehandle(com.fasterxml.jackson.databind.JsonNode input, StitchProcessor processor, DeploymentContext deploymentContext, Map<String, Object> params) This method is responsible for stitch transformation.type()Returns type that can be handled by this handler.voidvalidate(StitchProcessorDto processor) Method for processor validation during parsing/validation phase.
-
Method Details
-
type
String type()Returns type that can be handled by this handler.- Returns:
- type that can be handled by handler.
-
fileParameterName
String fileParameterName()Returns file parameter name for external file.- Returns:
- parameter name that corresponds to one that can be saved externally.
-
handle
com.fasterxml.jackson.databind.JsonNode handle(com.fasterxml.jackson.databind.JsonNode input, StitchProcessor processor, DeploymentContext deploymentContext, Map<String, Object> params) throws ExceptionThis method is responsible for stitch transformation. It should do whatever is expected from processor to transform input.- Parameters:
input- to handler asJsonNodeprocessor- that is being applieddeploymentContext- context for deployment associated with stitch transformationparams- parameters given to processor- Returns:
- transformed input with applied processor as
JsonNode. - Throws:
Exception- when handling of a processor failed
-
validate
Method for processor validation during parsing/validation phase.- Parameters:
processor- to be validated- Throws:
InvalidProcessorException- when processor can't pass validation
-