Main Page | Packages | Class Hierarchy | Alphabetical List | Class List | File List | Class Members | Related Pages

ProjectAttributes1.java

Go to the documentation of this file.
00001 
00058 package com.arcle.rmt.j2se.swing.vc.rqml;
00059 
00060 import javax.swing.*;
00061 import java.awt.BorderLayout;
00062 import java.awt.Insets;
00063 import java.util.Observable;
00064 
00065 import com.arcle.rmt.rqml.RQMLFirstClass;
00066 import com.arcle.rmt.rqml.Project;
00067 
00077 public class ProjectAttributes1 extends FirstClassPanel {
00078     public ProjectAttributes1(RQMLFirstClass fc) {
00079         super(fc);
00080         setName("Problem Statement");
00081     }
00082 
00083     //-------------------------------------------------------------------
00084     // View implementations
00085 
00086 
00087     //-------------------------------------------------------------------
00088     protected void initChildren() {
00089         lbProblem = createLabel("Problem");
00090 
00091         edProblem = createTextArea();
00092     }
00093 
00094     protected void layoutChildren() {
00095         JPanel p1, p2, p3;
00096         setLayout(new BorderLayout());
00097         // top row
00098         p1 = new JPanel();
00099             p1.setLayout(new BorderLayout());
00100             p1.add(lbProblem, BorderLayout.NORTH);
00101             p1.add(createScrollPane(edProblem), BorderLayout.CENTER);
00102         add(p1, BorderLayout.CENTER);
00103     }
00104 
00105     //-------------------------------------------------------------------
00106 
00107     protected void loadData() {
00108         RQMLFirstClass elem = getElement();
00109         if (elem instanceof Project) {
00110             Project prj = (Project) elem;
00111             edProblem.setText(prj.getProblem().getString());
00112         }
00113     }
00114 
00115     protected void saveData() {
00116         RQMLFirstClass elem = getElement();
00117         if (elem instanceof Project) {
00118             Project prj = (Project) elem;
00119             prj.getProblem().setString(edProblem.getText());
00120         }
00121     }
00122 
00123     //-------------------------------------------------------------------
00124     // Member Variables
00125 
00126     private JLabel lbProblem;
00127     private JTextArea edProblem;
00128 }

Generated on Fri Jun 18 19:51:23 2004 for Arcle Rambutan by doxygen 1.3.5