KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > org > continuent > sequoia > controller > requests > StoredProcedureCallResult


1 /**
2  * Sequoia: Database clustering technology.
3  * Copyright (C) 2006 Continuent, Inc.
4  * Contact: sequoia@continuent.org
5  *
6  * Licensed under the Apache License, Version 2.0 (the "License");
7  * you may not use this file except in compliance with the License.
8  * You may obtain a copy of the License at
9  *
10  * http://www.apache.org/licenses/LICENSE-2.0
11  *
12  * Unless required by applicable law or agreed to in writing, software
13  * distributed under the License is distributed on an "AS IS" BASIS,
14  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
15  * See the License for the specific language governing permissions and
16  * limitations under the License.
17  *
18  * Initial developer(s): Emmanuel Cecchet.
19  * Contributor(s): ______________________.
20  */

21
22 package org.continuent.sequoia.controller.requests;
23
24 import java.io.Serializable JavaDoc;
25
26 /**
27  * This class defines a StoredProcedureCallResult to store the result of a
28  * stored procedure call including information about the OUT and named
29  * parameters.
30  *
31  * @author <a HREF="mailto:emmanuel.cecchet@continuent.com">Emmanuel Cecchet</a>
32  * @version 1.0
33  */

34 public class StoredProcedureCallResult implements Serializable JavaDoc
35 {
36   private static final long serialVersionUID = -9116817669101507041L;
37
38   private Object JavaDoc result;
39   private StoredProcedure proc;
40
41   /**
42    * Creates a new <code>StoredProcedureCallResult</code> object
43    *
44    * @param proc the stored procedure call (including out and named parameters
45    * information)
46    * @param result the result of the call
47    */

48   public StoredProcedureCallResult(StoredProcedure proc, Object JavaDoc result)
49   {
50     this.proc = proc;
51     this.result = result;
52   }
53
54   /**
55    * Returns the result value.
56    *
57    * @return Returns the result.
58    */

59   public final Object JavaDoc getResult()
60   {
61     return result;
62   }
63
64   /**
65    * Returns the stored procedure object containing the parameters information
66    *
67    * @return a stored procedure object
68    */

69   public StoredProcedure getStoredProcedure()
70   {
71     return proc;
72   }
73
74 }
75
Popular Tags