View Javadoc

1   package org.apache.commons.contract;
2   
3   import java.util.Map;
4   
5   import org.apache.commons.contract.descriptor.ParameterDescriptor;
6   import org.apache.commons.contract.descriptor.ResultDescriptor;
7   
8   public interface Processor {
9       /**
10       * Implement this method to provide the logic of the processor
11       * 
12       * @param parameter a map containing the parameters for this process call.
13       *                  
14       * @return result
15       * @throws Exception 
16       */
17      public Result process(Map parameter, Context context) throws Exception;
18  
19      // The following methods describe the behaviour of the processor
20      // The parameters needed
21      public ParameterDescriptor[] getParameterDescriptors();
22  
23      // The states/results that this renderer generates
24      public ResultDescriptor[] getResultDescriptors();
25  }