KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > org > bsf > remoteIterator > common > ColumnMetadata


1 /* ******************************************************************************** *
2  * Copyright (c) 2002 - 2004 Bright Side Factory. All rights reserved. *
3  * *
4  * Redistribution and use in source and binary forms, with or without modification, *
5  * are permitted provided that the following conditions are met: *
6  * *
7  * 1. Redistributions of source code must retain the above copyright notice, this *
8  * list of conditions and the following disclaimer. *
9  * *
10  * 2. Redistributions in binary form must reproduce the above copyright notice, *
11  * this list of conditions and the following disclaimer in the documentation and/or *
12  * other materials provided with the distribution. *
13  * *
14  * 3. The end-user documentation included with the redistribution, if any, must *
15  * include the following acknowledgment: "This product includes software developed *
16  * by the Bright Side Factory (http://www.bs-factory.org/)." Alternately, this *
17  * acknowledgment may appear in the software itself, if and wherever such *
18  * third-party acknowledgments normally appear. *
19  * *
20  * 4. The names "Bright Side", "BS Framework" and "Bright Side Factory" must not be *
21  * used to endorse or promote products derived from this software without prior *
22  * written permission. For written permission, please contact info@bs-factory.org. *
23  * *
24  * 5. Products derived from this software may not be called "Bright Side", nor may *
25  * "Bright Side" appear in their name, without prior written permission of the *
26  * Bright Side Factory. *
27  * *
28  * THIS SOFTWARE IS PROVIDED ''AS IS'' BY THE COPYRIGHT OWNER AND ANY EXPRESSED OR *
29  * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF *
30  * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT *
31  * SHALL THE COPYRIGHT OWNER OR ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, *
32  * INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, *
33  * BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, *
34  * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF *
35  * LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE *
36  * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS OFTWARE, EVEN IF ADVISED *
37  * OF THE POSSIBILITY OF SUCH DAMAGE. *
38  * *
39  * ================================================================================ *
40  * *
41  * This software consists of voluntary contributions made by many individuals on *
42  * behalf of the Bright Side Factory. For more information on the Bright Side *
43  * Factory, please see http://www.bs-factory.org. *
44  * *
45  * ******************************************************************************** */

46 package org.bsf.remoteIterator.common;
47
48 import java.io.Serializable JavaDoc;
49
50 /**
51  * Stores the MetaData (ie. Columns types, JDBC informations) for the
52  * RemoteIterator.
53  *
54  * @see org.bsf.remoteIterator.server.RemoteIteratorBean
55  */

56 public class ColumnMetadata implements Serializable JavaDoc {
57     private int _scale;
58     private int _precision;
59     private int _columnType;
60     private String JavaDoc _tableName;
61     private String JavaDoc _columnName;
62     private String JavaDoc _schemaName;
63     private String JavaDoc _columnTypeName;
64     private String JavaDoc _columnClassName;
65
66     // *************************************************************************
67
// ******************************** Accessors ******************************
68
// *************************************************************************
69

70     public int getColumnType() {
71         return _columnType;
72     }
73
74     public void setColumnType( int p_columnType ) {
75         _columnType = p_columnType;
76     }
77
78     public String JavaDoc getColumnTypeName() {
79         return _columnTypeName;
80     }
81
82     public void setColumnTypeName( String JavaDoc p_columnTypeName ) {
83         _columnTypeName = p_columnTypeName;
84     }
85
86     public int getScale() {
87         return _scale;
88     }
89
90     public void setScale( int scale ) {
91         _scale = scale;
92     }
93
94     public int getPrecision() {
95         return _precision;
96     }
97
98     public void setPrecision( int p_precision ) {
99         _precision = p_precision;
100     }
101
102     public String JavaDoc getColumnClassName() {
103         return _columnClassName;
104     }
105
106     public void setColumnClassName( String JavaDoc p_columnClassName ) {
107         _columnClassName = p_columnClassName;
108     }
109
110     public String JavaDoc getColumnName() {
111         return _columnName;
112     }
113
114     public void setColumnName( String JavaDoc p_columnName ) {
115         _columnName = p_columnName;
116     }
117
118     public String JavaDoc getSchemaName() {
119         return _schemaName;
120     }
121
122     public void setSchemaName( String JavaDoc p_schemaName ) {
123         _schemaName = p_schemaName;
124     }
125
126     public String JavaDoc getTableName() {
127         return _tableName;
128     }
129
130     public void setTableName( String JavaDoc p_tableName ) {
131         _tableName = p_tableName;
132     }
133
134     public String JavaDoc toString() {
135         return "ColumnMetada ( " + _schemaName + ", " + _tableName + ", " + _columnName + ", " + _columnClassName + " )";
136     }
137 }
Popular Tags