Source Code Cross Referenced for DBSchemaPropertySheet.java in  » Database-ORM » db-ojb » org » apache » ojb » tools » mapping » reversedb » gui » Java Source Code / Java DocumentationJava Source Code and Java Documentation

Java Source Code / Java Documentation
1. 6.0 JDK Core
2. 6.0 JDK Modules
3. 6.0 JDK Modules com.sun
4. 6.0 JDK Modules com.sun.java
5. 6.0 JDK Modules sun
6. 6.0 JDK Platform
7. Ajax
8. Apache Harmony Java SE
9. Aspect oriented
10. Authentication Authorization
11. Blogger System
12. Build
13. Byte Code
14. Cache
15. Chart
16. Chat
17. Code Analyzer
18. Collaboration
19. Content Management System
20. Database Client
21. Database DBMS
22. Database JDBC Connection Pool
23. Database ORM
24. Development
25. EJB Server geronimo
26. EJB Server GlassFish
27. EJB Server JBoss 4.2.1
28. EJB Server resin 3.1.5
29. ERP CRM Financial
30. ESB
31. Forum
32. GIS
33. Graphic Library
34. Groupware
35. HTML Parser
36. IDE
37. IDE Eclipse
38. IDE Netbeans
39. Installer
40. Internationalization Localization
41. Inversion of Control
42. Issue Tracking
43. J2EE
44. JBoss
45. JMS
46. JMX
47. Library
48. Mail Clients
49. Net
50. Parser
51. PDF
52. Portal
53. Profiler
54. Project Management
55. Report
56. RSS RDF
57. Rule Engine
58. Science
59. Scripting
60. Search Engine
61. Security
62. Sevlet Container
63. Source Control
64. Swing Library
65. Template Engine
66. Test Coverage
67. Testing
68. UML
69. Web Crawler
70. Web Framework
71. Web Mail
72. Web Server
73. Web Services
74. Web Services apache cxf 2.0.1
75. Web Services AXIS2
76. Wiki Engine
77. Workflow Engines
78. XML
79. XML UI
Java
Java Tutorial
Java Open Source
Jar File Download
Java Articles
Java Products
Java by API
Photoshop Tutorials
Maya Tutorials
Flash Tutorials
3ds-Max Tutorials
Illustrator Tutorials
GIMP Tutorials
C# / C Sharp
C# / CSharp Tutorial
C# / CSharp Open Source
ASP.Net
ASP.NET Tutorial
JavaScript DHTML
JavaScript Tutorial
JavaScript Reference
HTML / CSS
HTML CSS Reference
C / ANSI-C
C Tutorial
C++
C++ Tutorial
Ruby
PHP
Python
Python Tutorial
Python Open Source
SQL Server / T-SQL
SQL Server / T-SQL Tutorial
Oracle PL / SQL
Oracle PL/SQL Tutorial
PostgreSQL
SQL / MySQL
MySQL Tutorial
VB.Net
VB.Net Tutorial
Flash / Flex / ActionScript
VBA / Excel / Access / Word
XML
XML Tutorial
Microsoft Office PowerPoint 2007 Tutorial
Microsoft Office Excel 2007 Tutorial
Microsoft Office Word 2007 Tutorial
Java Source Code / Java Documentation » Database ORM » db ojb » org.apache.ojb.tools.mapping.reversedb.gui 
Source Cross Referenced  Class Diagram Java Document (Java Doc) 


001:        package org.apache.ojb.tools.mapping.reversedb.gui;
002:
003:        /* Copyright 2002-2005 The Apache Software Foundation
004:         *
005:         * Licensed under the Apache License, Version 2.0 (the "License");
006:         * you may not use this file except in compliance with the License.
007:         * You may obtain a copy of the License at
008:         *
009:         *     http://www.apache.org/licenses/LICENSE-2.0
010:         *
011:         * Unless required by applicable law or agreed to in writing, software
012:         * distributed under the License is distributed on an "AS IS" BASIS,
013:         * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
014:         * See the License for the specific language governing permissions and
015:         * limitations under the License.
016:         */
017:
018:        /**
019:         *
020:         * @author <a href="mailto:bfl@florianbruckner.com">Florian Bruckner</a> 
021:         * @version $Id: DBSchemaPropertySheet.java,v 1.1.2.1 2005/12/21 22:32:02 tomdz Exp $
022:         */
023:        public class DBSchemaPropertySheet extends javax.swing.JPanel implements 
024:                PropertySheetView {
025:            org.apache.ojb.tools.mapping.reversedb.DBSchema aSchema;
026:
027:            /** Creates new form DBCatalogPropertySheet */
028:            public DBSchemaPropertySheet() {
029:                initComponents();
030:            }
031:
032:            private void readValuesFromSchema() {
033:                this .tfSchemaName.setText(aSchema.getSchemaName());
034:                this .cbEnabled.setSelected(aSchema.isEnabled());
035:                this .cbDisabledByParent.setSelected(!aSchema.getDBCatalog()
036:                        .isTreeEnabled());
037:            }
038:
039:            /** This method is called from within the constructor to
040:             * initialize the form.
041:             * WARNING: Do NOT modify this code. The content of this method is
042:             * always regenerated by the Form Editor.
043:             */
044:            private void initComponents()//GEN-BEGIN:initComponents
045:            {
046:                java.awt.GridBagConstraints gridBagConstraints;
047:
048:                jPanel1 = new javax.swing.JPanel();
049:                lblEnabled = new javax.swing.JLabel();
050:                cbEnabled = new javax.swing.JCheckBox();
051:                lblDisabledByParent = new javax.swing.JLabel();
052:                cbDisabledByParent = new javax.swing.JCheckBox();
053:                jLabel4 = new javax.swing.JLabel();
054:                jLabel3 = new javax.swing.JLabel();
055:                lblSchemaName = new javax.swing.JLabel();
056:                tfSchemaName = new javax.swing.JTextField();
057:
058:                setLayout(new java.awt.GridBagLayout());
059:
060:                addComponentListener(new java.awt.event.ComponentAdapter() {
061:                    public void componentShown(java.awt.event.ComponentEvent evt) {
062:                        formComponentShown(evt);
063:                    }
064:
065:                    public void componentHidden(
066:                            java.awt.event.ComponentEvent evt) {
067:                        formComponentHidden(evt);
068:                    }
069:                });
070:
071:                addHierarchyListener(new java.awt.event.HierarchyListener() {
072:                    public void hierarchyChanged(
073:                            java.awt.event.HierarchyEvent evt) {
074:                        formHierarchyChanged(evt);
075:                    }
076:                });
077:
078:                jPanel1.setLayout(new java.awt.GridLayout(4, 2));
079:
080:                lblEnabled.setText("enabled");
081:                lblEnabled.setDisplayedMnemonic('e');
082:                jPanel1.add(lblEnabled);
083:
084:                cbEnabled.setMnemonic('e');
085:                cbEnabled
086:                        .addActionListener(new java.awt.event.ActionListener() {
087:                            public void actionPerformed(
088:                                    java.awt.event.ActionEvent evt) {
089:                                cbEnabledActionPerformed(evt);
090:                            }
091:                        });
092:
093:                jPanel1.add(cbEnabled);
094:
095:                lblDisabledByParent.setText("disabled by Parent:");
096:                jPanel1.add(lblDisabledByParent);
097:
098:                cbDisabledByParent.setEnabled(false);
099:                cbDisabledByParent
100:                        .addActionListener(new java.awt.event.ActionListener() {
101:                            public void actionPerformed(
102:                                    java.awt.event.ActionEvent evt) {
103:                                cbDisabledByParentActionPerformed(evt);
104:                            }
105:                        });
106:
107:                jPanel1.add(cbDisabledByParent);
108:
109:                jPanel1.add(jLabel4);
110:
111:                jPanel1.add(jLabel3);
112:
113:                lblSchemaName.setText("Schema Name:");
114:                lblSchemaName.setLabelFor(tfSchemaName);
115:                jPanel1.add(lblSchemaName);
116:
117:                tfSchemaName.setEditable(false);
118:                tfSchemaName.setText("jTextField1");
119:                tfSchemaName.setBorder(null);
120:                jPanel1.add(tfSchemaName);
121:
122:                gridBagConstraints = new java.awt.GridBagConstraints();
123:                gridBagConstraints.fill = java.awt.GridBagConstraints.HORIZONTAL;
124:                gridBagConstraints.anchor = java.awt.GridBagConstraints.NORTH;
125:                gridBagConstraints.weightx = 1.0;
126:                gridBagConstraints.weighty = 1.0;
127:                add(jPanel1, gridBagConstraints);
128:
129:            }//GEN-END:initComponents
130:
131:            private void cbEnabledActionPerformed(java.awt.event.ActionEvent evt)//GEN-FIRST:event_cbEnabledActionPerformed
132:            {//GEN-HEADEREND:event_cbEnabledActionPerformed
133:                // Add your handling code here:
134:                this .aSchema.setEnabled(cbEnabled.isSelected());
135:            }//GEN-LAST:event_cbEnabledActionPerformed
136:
137:            private void cbDisabledByParentActionPerformed(
138:                    java.awt.event.ActionEvent evt)//GEN-FIRST:event_cbDisabledByParentActionPerformed
139:            {//GEN-HEADEREND:event_cbDisabledByParentActionPerformed
140:                // Add your handling code here:
141:            }//GEN-LAST:event_cbDisabledByParentActionPerformed
142:
143:            private void formHierarchyChanged(java.awt.event.HierarchyEvent evt)//GEN-FIRST:event_formHierarchyChanged
144:            {//GEN-HEADEREND:event_formHierarchyChanged
145:                // Add your handling code here:
146:                readValuesFromSchema();
147:            }//GEN-LAST:event_formHierarchyChanged
148:
149:            private void formComponentHidden(java.awt.event.ComponentEvent evt)//GEN-FIRST:event_formComponentHidden
150:            {//GEN-HEADEREND:event_formComponentHidden
151:                // Add your handling code here:
152:            }//GEN-LAST:event_formComponentHidden
153:
154:            private void formComponentShown(java.awt.event.ComponentEvent evt)//GEN-FIRST:event_formComponentShown
155:            {//GEN-HEADEREND:event_formComponentShown
156:                // Add your handling code here:
157:            }//GEN-LAST:event_formComponentShown
158:
159:            public void setModel(PropertySheetModel pm) {
160:                if (pm instanceof  org.apache.ojb.tools.mapping.reversedb.DBSchema) {
161:                    this .aSchema = (org.apache.ojb.tools.mapping.reversedb.DBSchema) pm;
162:                    this .readValuesFromSchema();
163:                } else
164:                    throw new IllegalArgumentException();
165:
166:            }
167:
168:            // Variables declaration - do not modify//GEN-BEGIN:variables
169:            private javax.swing.JCheckBox cbDisabledByParent;
170:            private javax.swing.JPanel jPanel1;
171:            private javax.swing.JLabel lblEnabled;
172:            private javax.swing.JLabel lblSchemaName;
173:            private javax.swing.JCheckBox cbEnabled;
174:            private javax.swing.JTextField tfSchemaName;
175:            private javax.swing.JLabel lblDisabledByParent;
176:            private javax.swing.JLabel jLabel4;
177:            private javax.swing.JLabel jLabel3;
178:            // End of variables declaration//GEN-END:variables
179:
180:        }
181:
182:        /***************************** changelog *****************************
183:         // $log$
184:         /***************************** changelog *****************************/
w__w__w.___j___a___v___a__2s.___co___m__ | Contact Us
Copyright 2009 - 12 Demo Source and Support. All rights reserved.
All other trademarks are property of their respective owners.