View Javadoc
1   /*
2    * Copyright (c) 1997, 2012, Oracle and/or its affiliates. All rights reserved.
3    * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
4    *
5    * This code is free software; you can redistribute it and/or modify it
6    * under the terms of the GNU General Public License version 2 only, as
7    * published by the Free Software Foundation.  Oracle designates this
8    * particular file as subject to the "Classpath" exception as provided
9    * by Oracle in the LICENSE file that accompanied this code.
10   *
11   * This code is distributed in the hope that it will be useful, but WITHOUT
12   * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
13   * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
14   * version 2 for more details (a copy is included in the LICENSE file that
15   * accompanied this code).
16   *
17   * You should have received a copy of the GNU General Public License version
18   * 2 along with this work; if not, write to the Free Software Foundation,
19   * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
20   *
21   * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
22   * or visit www.oracle.com if you need additional information or have any
23   * questions.
24   */
25  
26  package com.oracle.webservices.internal.api.databinding;
27  
28  import java.lang.reflect.Method;
29  
30  /**
31   * On the client or service-requestor side, a JavaCallInfo object represents a
32   * method call on the service proxy to be serialized as a SOAP request message
33   * to be sent to the service. A SOAP response message returned to the service
34   * client is deserialized as an update to the JavaCallInfo object which is used
35   * to generated the request.
36   * <p>
37   * </p>
38   * On the server or service provider side, a SOAP request message is
39   * deserialized to a JavaCallInfo object which can be used to determine which
40   * method to call, and get the parameter values to call the back-end service
41   * implementation object. The return value or exception returned from the
42   * service implementation should be set to the JavaCallInfo object which then
43   * can be used to serialize to a A SOAP response or fault message to be sent
44   * back to the service client.
45   *
46   * @author shih-chang.chen@oracle.com
47   */
48  public interface JavaCallInfo {
49  
50          /**
51           * Gets the method of this JavaCallInfo
52           *
53           * @return the method
54           */
55          public Method getMethod();
56  
57  //      /**
58  //       * Sets the method of this JavaCallInfo
59  //       *
60  //       * @param method The method to set
61  //       */
62  //      public void setMethod(Method method);
63  
64          /**
65           * Gets the parameters of this JavaCallInfo
66           *
67           * @return The parameters
68           */
69          public Object[] getParameters();
70  
71  //      /**
72  //       * Sets the parameters of this JavaCallInfo
73  //       *
74  //       * @param parameters
75  //       *            the parameters to set
76  //       */
77  //      public void setParameters(Object[] parameters);
78  
79          /**
80           * Gets the returnValue of this JavaCallInfo
81           *
82           * @return the returnValue
83           */
84          public Object getReturnValue();
85  
86          /**
87           * Sets the returnValue of this JavaCallInfo
88           *
89           * @param returnValue
90           *            the returnValue to set
91           */
92          public void setReturnValue(Object returnValue);
93  
94          /**
95           * Gets the exception of this JavaCallInfo
96           *
97           * @return the exception
98           */
99          public Throwable getException();
100 
101         /**
102          * Sets the exception of this JavaCallInfo
103          *
104          * @param exception
105          *            the exception to set
106          */
107         public void setException(Throwable exception);
108 }