View Javadoc

1   package org.kuali.rice.kew.framework.document.lookup;
2   
3   import org.kuali.rice.core.api.exception.RiceIllegalArgumentException;
4   import org.kuali.rice.core.api.uif.RemotableAttributeError;
5   import org.kuali.rice.core.api.uif.RemotableAttributeField;
6   import org.kuali.rice.core.api.util.jaxb.MultiValuedStringMapAdapter;
7   import org.kuali.rice.kew.api.KewApiConstants;
8   import org.kuali.rice.kew.api.document.lookup.DocumentLookupConfiguration;
9   import org.kuali.rice.kew.api.document.lookup.DocumentLookupCriteria;
10  import org.kuali.rice.kew.api.document.lookup.DocumentLookupResult;
11  import org.kuali.rice.kew.framework.KewFrameworkServiceLocator;
12  
13  import javax.jws.WebMethod;
14  import javax.jws.WebParam;
15  import javax.jws.WebResult;
16  import javax.jws.WebService;
17  import javax.jws.soap.SOAPBinding;
18  import javax.xml.bind.annotation.XmlElement;
19  import javax.xml.bind.annotation.XmlElementWrapper;
20  import javax.xml.bind.annotation.adapters.XmlJavaTypeAdapter;
21  import java.util.List;
22  import java.util.Map;
23  import java.util.Set;
24  
25  /**
26   * TODO...
27   *
28   * @author Kuali Rice Team (rice.collab@kuali.org)
29   */
30  @WebService(name = KewFrameworkServiceLocator.DOCUMENT_LOOKUP_CUSTOMIZATION_HANDLER_SERVICE, targetNamespace = KewApiConstants.Namespaces.KEW_NAMESPACE_2_0)
31  @SOAPBinding(style = SOAPBinding.Style.DOCUMENT, use = SOAPBinding.Use.LITERAL, parameterStyle = SOAPBinding.ParameterStyle.WRAPPED)
32  public interface DocumentLookupCustomizationHandlerService {
33  
34      @WebMethod(operationName = "getDocumentLookupConfiguration")
35  	@WebResult(name = "documentLookupConfiguration")
36  	@XmlElement(name = "documentLookupConfiguration", required = false)
37      DocumentLookupConfiguration getDocumentLookupConfiguration(
38              @WebParam(name = "documentTypeName") String documentTypeName,
39              @WebParam(name = "searchableAttributeNames") List<String> searchableAttributeNames
40      ) throws RiceIllegalArgumentException;
41  
42      @WebMethod(operationName = "validateSearchFieldParameters")
43      @WebResult(name = "searchFieldErrors")
44      @XmlElementWrapper(name = "searchFieldErrors", required = false)
45      @XmlElement(name = "searchFieldError", required = false)
46      List<RemotableAttributeError> validateSearchFieldParameters(
47              @WebParam(name = "documentTypeName") String documentTypeName,
48              @WebParam(name = "searchableAttributeNames") List<String> searchableAttributeNames,
49              @WebParam(name = "parameters")
50              @XmlJavaTypeAdapter(MultiValuedStringMapAdapter.class) Map<String, List<String>> parameters
51      ) throws RiceIllegalArgumentException;
52  
53      @WebMethod(operationName = "customizeCriteria")
54      @WebResult(name = "documentLookupCriteria")
55      @XmlElement(name = "documentLookupCriteria", required = false)
56      DocumentLookupCriteria customizeCriteria(
57              @WebParam(name = "documentLookupCriteria") DocumentLookupCriteria documentLookupCriteria,
58              @WebParam(name = "customizerName") String customizerName
59      ) throws RiceIllegalArgumentException;
60  
61      @WebMethod(operationName = "customizeClearCriteria")
62      @WebResult(name = "documentLookupCriteria")
63      @XmlElement(name = "documentLookupCriteria", required = false)
64      DocumentLookupCriteria customizeClearCriteria(
65              @WebParam(name = "documentLookupCriteria") DocumentLookupCriteria documentLookupCriteria,
66              @WebParam(name = "customizerName") String customizerName
67      ) throws RiceIllegalArgumentException;
68  
69      @WebMethod(operationName = "customizeResultSetFields")
70      @WebResult(name = "resultSetFields")
71      @XmlElementWrapper(name = "resultSetFields", required = false)
72      @XmlElement(name = "resultSetField", required = false)
73      List<RemotableAttributeField> customizeResultSetFields(
74              @WebParam(name = "documentLookupCriteria") DocumentLookupCriteria documentLookupCriteria,
75              @WebParam(name = "defaultResultSetFields") List<RemotableAttributeField> defaultResultSetFields,
76              @WebParam(name = "customizerName") String customizerName
77      ) throws RiceIllegalArgumentException;
78  
79      @WebMethod(operationName = "customizeResults")
80      @WebResult(name = "results")
81      @XmlElementWrapper(name = "results", required = false)
82      @XmlElement(name = "result", required = false)
83      List<DocumentLookupResult> customizeResults(
84              @WebParam(name = "documentLookupCriteria") DocumentLookupCriteria documentLookupCriteria,
85              @WebParam(name = "defaultResults") List<DocumentLookupResult> defaultResults,
86              @WebParam(name = "customizerName") String customizerName
87      ) throws RiceIllegalArgumentException;
88  
89      @WebMethod(operationName = "getEnabledCustomizations")
90      @WebResult(name = "enabledCustomizations")
91      @XmlElementWrapper(name = "enabledCustomizations", required = false)
92      @XmlElement(name = "enabledCustomization", required = false)
93      Set<DocumentLookupCustomization> getEnabledCustomizations(
94              @WebParam(name = "documentTypeName") String documentTypeName,
95              @WebParam(name = "customizerName") String customizerName
96      ) throws RiceIllegalArgumentException;
97  
98  }