pipe.modules.simulation
Class Simulation

java.lang.Object
  |
  +--pipe.modules.simulation.Simulation
All Implemented Interfaces:
Module

public class Simulation
extends java.lang.Object
implements Module

Title:

Description:

Copyright: Copyright (c) 2003

Company:

Version:
1.0
Author:
unascribed

Inner Class Summary
 class Simulation.Evaluate
           
(package private)  class Simulation.HandleControl
           
 class Simulation.PrintableHTMLEditor
           
 
Field Summary
protected  double[] averageTokens
           
private  javax.swing.JToolBar buttonBar
           
private  java.awt.Point center
           
(package private) static int COMPARE
           
(package private) static int COMPARISON_BROWSE
           
private  javax.swing.JButton comparisonButton
           
private  DataLayer comparisondataLayer
           
private  javax.swing.JTextField comparisonTextField
           
(package private) static int CURRENT_NET
           
private  java.awt.Font defaultLabel
           
private  Simulation.PrintableHTMLEditor editorPane
           
protected  double[] error
           
private  int fontScale
           
private  java.awt.GridBagLayout gridbag
           
private  java.awt.GridBagConstraints gridbagConstraints
           
private  javax.swing.JFrame guiFrame
           
private  int INT_FIELD_SIZE
           
private  javax.swing.JButton load
           
private  javax.swing.JPanel mainPanel
           
private  javax.swing.JPanel mainSettingsOuterPanel
           
private  javax.swing.JPanel mainSettingsPanel
           
private  java.awt.Toolkit mainToolKit
           
private static java.lang.String MODULE_NAME
           
(package private) static int NO_ACTION
           
protected  int no_of_cycles
           
protected  int no_of_firings
           
private  javax.swing.JLabel noOfCycles
           
private  javax.swing.JTextField noOfCyclesText
           
private  javax.swing.JLabel noOfFirings
           
private  javax.swing.JTextField noOfFiringsText
           
private  javax.swing.JFrame outputFrame
           
private  java.io.File outputHTML
           
private  java.io.FileWriter outputWriter
           
private  javax.swing.JButton print
           
private  DataLayer refdataLayer
           
private  javax.swing.JButton save
           
private  javax.swing.JScrollPane scrollPane
           
private  java.awt.Font smallDefaultLabel
           
(package private) static int SOURCE_BROWSE
           
private  javax.swing.JButton sourceButton
           
private  javax.swing.JCheckBox sourceCheckBox
           
private  DataLayer sourcedataLayer
           
private  javax.swing.JLabel sourceLabel
           
private  javax.swing.JTextField sourceTextField
           
private  java.awt.Insets spacing
           
private  int TEXT_FIELD_SIZE
           
private  int windowHeight
           
private  java.awt.Dimension windowSize
           
private  int windowTopLeftCornerX
           
private  int windowTopLeftCornerY
           
private  int windowWidth
           
 
Constructor Summary
Simulation()
           
Simulation(DataLayer pnmlData)
           
 
Method Summary
private  void displayResults()
           
 java.lang.String getName()
           
private  void initGuiFrame()
           
 void load()
           
 void run(DataLayer pnmlData)
           
private  void runSimulation()
           
 void saveas(java.lang.String text)
           
private  void setUpButtonBar()
           
private  void setUpPetriNetPanel(javax.swing.JPanel panel)
           
private  void setupResults()
           
private  void setUpSettingsPanel(javax.swing.JPanel panel)
           
private  void warnUser(java.lang.String message, javax.swing.JFrame frame)
           
private  void writeHTML(java.lang.String fileName)
           
 
Methods inherited from class java.lang.Object
, clone, equals, finalize, getClass, hashCode, notify, notifyAll, registerNatives, toString, wait, wait, wait
 

Field Detail

MODULE_NAME

private static final java.lang.String MODULE_NAME

guiFrame

private javax.swing.JFrame guiFrame

outputFrame

private javax.swing.JFrame outputFrame

mainToolKit

private final java.awt.Toolkit mainToolKit

windowSize

private final java.awt.Dimension windowSize

center

private final java.awt.Point center

windowWidth

private final int windowWidth

windowHeight

private final int windowHeight

windowTopLeftCornerX

private final int windowTopLeftCornerX

windowTopLeftCornerY

private final int windowTopLeftCornerY

fontScale

private int fontScale

mainPanel

private javax.swing.JPanel mainPanel

gridbag

private java.awt.GridBagLayout gridbag

gridbagConstraints

private java.awt.GridBagConstraints gridbagConstraints

mainSettingsPanel

private javax.swing.JPanel mainSettingsPanel

mainSettingsOuterPanel

private javax.swing.JPanel mainSettingsOuterPanel

scrollPane

private javax.swing.JScrollPane scrollPane

editorPane

private Simulation.PrintableHTMLEditor editorPane

TEXT_FIELD_SIZE

private final int TEXT_FIELD_SIZE

INT_FIELD_SIZE

private final int INT_FIELD_SIZE

sourceTextField

private javax.swing.JTextField sourceTextField

comparisonTextField

private javax.swing.JTextField comparisonTextField

defaultLabel

private java.awt.Font defaultLabel

smallDefaultLabel

private java.awt.Font smallDefaultLabel

noOfFirings

private javax.swing.JLabel noOfFirings

noOfCycles

private javax.swing.JLabel noOfCycles

noOfFiringsText

private javax.swing.JTextField noOfFiringsText

noOfCyclesText

private javax.swing.JTextField noOfCyclesText

no_of_firings

protected int no_of_firings

no_of_cycles

protected int no_of_cycles

averageTokens

protected double[] averageTokens

error

protected double[] error

load

private javax.swing.JButton load

print

private javax.swing.JButton print

save

private javax.swing.JButton save

sourceButton

private javax.swing.JButton sourceButton

comparisonButton

private javax.swing.JButton comparisonButton

sourceLabel

private javax.swing.JLabel sourceLabel

buttonBar

private javax.swing.JToolBar buttonBar

sourcedataLayer

private DataLayer sourcedataLayer

comparisondataLayer

private DataLayer comparisondataLayer

outputHTML

private java.io.File outputHTML

outputWriter

private java.io.FileWriter outputWriter

spacing

private java.awt.Insets spacing

refdataLayer

private DataLayer refdataLayer

sourceCheckBox

private javax.swing.JCheckBox sourceCheckBox

NO_ACTION

static final int NO_ACTION

CURRENT_NET

static final int CURRENT_NET

SOURCE_BROWSE

static final int SOURCE_BROWSE

COMPARISON_BROWSE

static final int COMPARISON_BROWSE

COMPARE

static final int COMPARE
Constructor Detail

Simulation

public Simulation(DataLayer pnmlData)

Simulation

public Simulation()
Method Detail

run

public void run(DataLayer pnmlData)
Specified by:
run in interface Module

getName

public java.lang.String getName()
Specified by:
getName in interface Module

initGuiFrame

private void initGuiFrame()
                   throws java.lang.Exception

setUpPetriNetPanel

private void setUpPetriNetPanel(javax.swing.JPanel panel)

setUpSettingsPanel

private void setUpSettingsPanel(javax.swing.JPanel panel)

warnUser

private void warnUser(java.lang.String message,
                      javax.swing.JFrame frame)

runSimulation

private void runSimulation()

writeHTML

private void writeHTML(java.lang.String fileName)

setupResults

private void setupResults()
                   throws java.io.IOException

displayResults

private void displayResults()
                     throws java.io.IOException

setUpButtonBar

private void setUpButtonBar()

load

public void load()

saveas

public void saveas(java.lang.String text)
            throws java.io.IOException