[kepler-code] r28843 - in releases/release-branches/workflow-scheduler-gui-1.0/src/org/kepler/workflowscheduler/gui: . configurationwizard
tao at ecoinformatics.org
tao at ecoinformatics.org
Fri Oct 28 11:18:31 PDT 2011
Author: tao
Date: 2011-10-28 11:18:31 -0700 (Fri, 28 Oct 2011)
New Revision: 28843
Added:
releases/release-branches/workflow-scheduler-gui-1.0/src/org/kepler/workflowscheduler/gui/configurationwizard/KnownWorkflowRunEnginePanel.java
releases/release-branches/workflow-scheduler-gui-1.0/src/org/kepler/workflowscheduler/gui/configurationwizard/WorkflowRunEngineConfigurationChangeListener.java
releases/release-branches/workflow-scheduler-gui-1.0/src/org/kepler/workflowscheduler/gui/configurationwizard/WorkflowRunEngineConfigurationDialog.java
Modified:
releases/release-branches/workflow-scheduler-gui-1.0/src/org/kepler/workflowscheduler/gui/WorkflowSchedulerServerInstallationInfoPanel.java
Log:
Merge to the branch for cofiguring workflow run engine by a gui.
Modified: releases/release-branches/workflow-scheduler-gui-1.0/src/org/kepler/workflowscheduler/gui/WorkflowSchedulerServerInstallationInfoPanel.java
===================================================================
--- releases/release-branches/workflow-scheduler-gui-1.0/src/org/kepler/workflowscheduler/gui/WorkflowSchedulerServerInstallationInfoPanel.java 2011-10-28 18:09:42 UTC (rev 28842)
+++ releases/release-branches/workflow-scheduler-gui-1.0/src/org/kepler/workflowscheduler/gui/WorkflowSchedulerServerInstallationInfoPanel.java 2011-10-28 18:18:31 UTC (rev 28843)
@@ -49,7 +49,7 @@
import org.kepler.module.workflowschedulergui.Initialize;
import org.kepler.workflowscheduler.gui.configurationwizard.OpenWorkflowSchedulerURLConfigDialogAction;
-import com.sun.jndi.toolkit.url.UrlUtil;
+//import com.sun.jndi.toolkit.url.UrlUtil;
import ptolemy.actor.gui.TableauFrame;
Added: releases/release-branches/workflow-scheduler-gui-1.0/src/org/kepler/workflowscheduler/gui/configurationwizard/KnownWorkflowRunEnginePanel.java
===================================================================
--- releases/release-branches/workflow-scheduler-gui-1.0/src/org/kepler/workflowscheduler/gui/configurationwizard/KnownWorkflowRunEnginePanel.java (rev 0)
+++ releases/release-branches/workflow-scheduler-gui-1.0/src/org/kepler/workflowscheduler/gui/configurationwizard/KnownWorkflowRunEnginePanel.java 2011-10-28 18:18:31 UTC (rev 28843)
@@ -0,0 +1,101 @@
+package org.kepler.workflowscheduler.gui.configurationwizard;
+
+import java.awt.BorderLayout;
+import java.awt.Dimension;
+
+import javax.swing.BorderFactory;
+import javax.swing.JPanel;
+import javax.swing.JScrollPane;
+import javax.swing.JTable;
+import javax.swing.border.TitledBorder;
+
+import org.kepler.workflowscheduler.gui.ScheduleTableModel;
+import org.kepler.workflowscheduler.gui.WorkflowRunEngine;
+
+
+public class KnownWorkflowRunEnginePanel extends JPanel implements WorkflowRunEngineConfigurationChangeListener
+{
+ private WorkflowRunEngine[] engineList = null;
+ private KnownWorkflowRunEngineTableModel engineTableModel = null;
+ private JTable engineTable = null;
+
+ /**
+ * Constructor
+ * @param engineList
+ */
+ public KnownWorkflowRunEnginePanel(WorkflowRunEngine[] engineList)
+ {
+ this.engineList = engineList;
+ }
+ /*
+ * Initialize the panel
+ */
+ private void initialize()
+ {
+
+ this.setLayout(new BorderLayout());
+ //JTableHeader header = scheduleTable.getTableHeader();
+ //header.setBackground(Color.LIGHT_GRAY);
+ engineTableModel = new KnownWorkflowRunEngineTableModel(engineList);
+ engineTable = new JTable(engineTableModel);
+ engineTable.setAutoCreateColumnsFromModel(false);
+ JScrollPane scrollPane = new JScrollPane(engineTable);
+ //scrollPane.setPreferredSize(new Dimension(800, 180));
+ add(scrollPane, BorderLayout.CENTER);
+
+ }
+
+ /*
+ * Update the table after the table data model was changed
+ */
+ private void updateTable()
+ {
+ engineTableModel = new KnownWorkflowRunEngineTableModel(engineList);
+ engineTable.setModel(engineTableModel);
+ //scheduleTableModel.fireTableDataChanged();
+ engineTable.repaint();
+ engineTable.validate();
+ //System.out.println("After repaint table");
+ }
+
+
+ /**
+ * Add a new engine to the configuration
+ * @param engine then engine will be added
+ */
+ public void add(WorkflowRunEngine engine)
+ {
+ if(engine != null)
+ {
+ if(engineList == null )
+ {
+ engineList = new WorkflowRunEngine[1];
+ engineList[0] = engine;
+ }
+ else
+ {
+
+ WorkflowRunEngine[] oldArray = engineList;
+ int size = engineList.length;
+ int newSize = size+1;
+ engineList = new WorkflowRunEngine[newSize];
+ engineList[0]= engine;
+ for(int i=0; i<size; i++)
+ {
+ engineList[i+1] = oldArray[i];
+ }
+ }
+ updateTable();
+ }
+ }
+
+ /**
+ * Delete an engine.
+ * @param engine the engine will be deleted
+ */
+ public void delete(WorkflowRunEngine engine)
+ {
+
+ }
+
+}
Added: releases/release-branches/workflow-scheduler-gui-1.0/src/org/kepler/workflowscheduler/gui/configurationwizard/WorkflowRunEngineConfigurationChangeListener.java
===================================================================
--- releases/release-branches/workflow-scheduler-gui-1.0/src/org/kepler/workflowscheduler/gui/configurationwizard/WorkflowRunEngineConfigurationChangeListener.java (rev 0)
+++ releases/release-branches/workflow-scheduler-gui-1.0/src/org/kepler/workflowscheduler/gui/configurationwizard/WorkflowRunEngineConfigurationChangeListener.java 2011-10-28 18:18:31 UTC (rev 28843)
@@ -0,0 +1,52 @@
+/**
+ * Copyright (c) 2010 The Regents of the University of California.
+ * All rights reserved.
+ *
+ * '$Author: tao $'
+ * '$Date: 2010-06-03 16:45:10 -0700 (Thu, 03 Jun 2010) $'
+ * '$Revision: 24730 $'
+ *
+ * Permission is hereby granted, without written agreement and without
+ * license or royalty fees, to use, copy, modify, and distribute this
+ * software and its documentation for any purpose, provided that the above
+ * copyright notice and the following two paragraphs appear in all copies
+ * of this software.
+ *
+ * IN NO EVENT SHALL THE UNIVERSITY OF CALIFORNIA BE LIABLE TO ANY PARTY
+ * FOR DIRECT, INDIRECT, SPECIAL, INCIDENTAL, OR CONSEQUENTIAL DAMAGES
+ * ARISING OUT OF THE USE OF THIS SOFTWARE AND ITS DOCUMENTATION, EVEN IF
+ * THE UNIVERSITY OF CALIFORNIA HAS BEEN ADVISED OF THE POSSIBILITY OF
+ * SUCH DAMAGE.
+ *
+ * THE UNIVERSITY OF CALIFORNIA SPECIFICALLY DISCLAIMS ANY WARRANTIES,
+ * INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
+ * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. THE SOFTWARE
+ * PROVIDED HEREUNDER IS ON AN "AS IS" BASIS, AND THE UNIVERSITY OF
+ * CALIFORNIA HAS NO OBLIGATION TO PROVIDE MAINTENANCE, SUPPORT, UPDATES,
+ * ENHANCEMENTS, OR MODIFICATIONS.
+ *
+ */
+package org.kepler.workflowscheduler.gui.configurationwizard;
+
+import org.kepler.workflowscheduler.gui.WorkflowRunEngine;
+
+/**
+ * A calling back interface when WorkflowRunEngineConfiguration is changed.
+ * This is for the gui display.
+ * @author tao
+ *
+ */
+public interface WorkflowRunEngineConfigurationChangeListener
+{
+ /**
+ * Add a new engine to the configuration
+ * @param engine then engine will be added
+ */
+ public void add(WorkflowRunEngine engine);
+
+ /**
+ * Delete an engine.
+ * @param engine the engine will be deleted
+ */
+ public void delete(WorkflowRunEngine engine);
+}
Added: releases/release-branches/workflow-scheduler-gui-1.0/src/org/kepler/workflowscheduler/gui/configurationwizard/WorkflowRunEngineConfigurationDialog.java
===================================================================
--- releases/release-branches/workflow-scheduler-gui-1.0/src/org/kepler/workflowscheduler/gui/configurationwizard/WorkflowRunEngineConfigurationDialog.java (rev 0)
+++ releases/release-branches/workflow-scheduler-gui-1.0/src/org/kepler/workflowscheduler/gui/configurationwizard/WorkflowRunEngineConfigurationDialog.java 2011-10-28 18:18:31 UTC (rev 28843)
@@ -0,0 +1,34 @@
+/**
+ * Copyright (c) 2010 The Regents of the University of California.
+ * All rights reserved.
+ *
+ * '$Author: tao $'
+ * '$Date: 2010-06-03 16:45:10 -0700 (Thu, 03 Jun 2010) $'
+ * '$Revision: 24730 $'
+ *
+ * Permission is hereby granted, without written agreement and without
+ * license or royalty fees, to use, copy, modify, and distribute this
+ * software and its documentation for any purpose, provided that the above
+ * copyright notice and the following two paragraphs appear in all copies
+ * of this software.
+ *
+ * IN NO EVENT SHALL THE UNIVERSITY OF CALIFORNIA BE LIABLE TO ANY PARTY
+ * FOR DIRECT, INDIRECT, SPECIAL, INCIDENTAL, OR CONSEQUENTIAL DAMAGES
+ * ARISING OUT OF THE USE OF THIS SOFTWARE AND ITS DOCUMENTATION, EVEN IF
+ * THE UNIVERSITY OF CALIFORNIA HAS BEEN ADVISED OF THE POSSIBILITY OF
+ * SUCH DAMAGE.
+ *
+ * THE UNIVERSITY OF CALIFORNIA SPECIFICALLY DISCLAIMS ANY WARRANTIES,
+ * INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
+ * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. THE SOFTWARE
+ * PROVIDED HEREUNDER IS ON AN "AS IS" BASIS, AND THE UNIVERSITY OF
+ * CALIFORNIA HAS NO OBLIGATION TO PROVIDE MAINTENANCE, SUPPORT, UPDATES,
+ * ENHANCEMENTS, OR MODIFICATIONS.
+ *
+ */
+package org.kepler.workflowscheduler.gui.configurationwizard;
+
+public class WorkflowRunEngineConfigurationDialog
+{
+
+}
More information about the Kepler-cvs
mailing list