jlink.flowchart
Class JLWorksheet

java.lang.Object
  extended by java.awt.Component
      extended by java.awt.Container
          extended by javax.swing.JComponent
              extended by javax.swing.JLayeredPane
                  extended by jlink.flowchart.JLPage
                      extended by jlink.flowchart.JLWorksheet
All Implemented Interfaces:
java.awt.image.ImageObserver, java.awt.MenuContainer, java.io.Serializable, javax.accessibility.Accessible

public class JLWorksheet
extends JLPage

An implementation of the IBM standard Flowchart Worksheet (X20-8021). X20-8021 provides a standard worksheet template that can be used when prototyping and documenting programs, processes and many other things that can be described with a flowchart. The graphical interface allows WYSIWYG editing.

Author:
jasonkb
See Also:
Serialized Form

Nested Class Summary
 
Nested classes/interfaces inherited from class javax.swing.JLayeredPane
javax.swing.JLayeredPane.AccessibleJLayeredPane
 
Nested classes/interfaces inherited from class javax.swing.JComponent
javax.swing.JComponent.AccessibleJComponent
 
Nested classes/interfaces inherited from class java.awt.Container
java.awt.Container.AccessibleAWTContainer
 
Nested classes/interfaces inherited from class java.awt.Component
java.awt.Component.AccessibleAWTComponent, java.awt.Component.BaselineResizeBehavior, java.awt.Component.BltBufferStrategy, java.awt.Component.FlipBufferStrategy
 
Field Summary
protected  java.lang.String author
          The author of this chart.
protected  int chartID
          The chart ID.
protected  java.lang.String chartName
          The name of this flowchart.
protected  java.lang.String date
          The date of authoring this chart.
protected  java.lang.String description
          The chart description to appear in the footer.
protected  boolean displayFlowCells
          Property detailing if the flow cells are to be displayed on the JLWorksheet.
protected  int page
          The page number of this chart.
protected  java.lang.String processName
          The process which this chart is showing.
protected  int processNumber
          The number of this process.
 
Fields inherited from class jlink.flowchart.JLPage
bgTransparency, bordersOn, bottomMargin, containerBackgroundColor, containerBorderColor, containerShadowColor, CONVERT_CM_IN, CONVERT_IN_CM, currentOrientation, h, leftMargin, marginsOn, ORIENTATION_LANDSCAPE, ORIENTATION_PORTRAIT, ORIENTATION_SQUARE, PAGE_A4, PAGE_PAPER, PAGE_PLAIN, PAGE_TRANSPARENT, pageType, rightMargin, SCREEN_HEIGHT, SCREEN_RESOLUTION, SCREEN_WIDTH, shadowsOn, topMargin, UNIT_CM, UNIT_INCH, UNIT_PIXEL, w
 
Fields inherited from class javax.swing.JLayeredPane
DEFAULT_LAYER, DRAG_LAYER, FRAME_CONTENT_LAYER, LAYER_PROPERTY, MODAL_LAYER, PALETTE_LAYER, POPUP_LAYER
 
Fields inherited from class javax.swing.JComponent
accessibleContext, listenerList, TOOL_TIP_TEXT_KEY, ui, UNDEFINED_CONDITION, WHEN_ANCESTOR_OF_FOCUSED_COMPONENT, WHEN_FOCUSED, WHEN_IN_FOCUSED_WINDOW
 
Fields inherited from class java.awt.Component
BOTTOM_ALIGNMENT, CENTER_ALIGNMENT, LEFT_ALIGNMENT, RIGHT_ALIGNMENT, TOP_ALIGNMENT
 
Fields inherited from interface java.awt.image.ImageObserver
ABORT, ALLBITS, ERROR, FRAMEBITS, HEIGHT, PROPERTIES, SOMEBITS, WIDTH
 
Constructor Summary
JLWorksheet()
           
 
Method Summary
 java.lang.String getAuthor()
          The author is the person who is responsible for creating the chart.
 int getChartID()
          The chart ID is set by the author(s) and should be unique in that other charts that refer to it can do so, so that end users of the chart are clearly able to follow the charts references.
 java.lang.String getChartName()
          An author may have several different charts.
 java.lang.String getDate()
          The date that this chart was authored.
 java.lang.String getDescription()
          The description of a JLWorksheet is a footer string that is placed at the bottom of the page, which serves to describe what is being detailed inside the flowchart.
 int getPage()
          There may be several pages in a document, and other pages may refer into these pages.
 java.lang.String getProcessName()
          Within a chart there may be several processes being described in the same document.
 int getProcessNumber()
          Within a chart there may be several processes being described in the same document.
 java.lang.String getUIClassID()
          Returns the UI string for JLPage which is PageUI.UI_CLASS_ID
 boolean isFlowCellsEnabled()
          Flow cells are the boxes in a JLWorksheet that serve to hold processes in a chart.
 void setAuthor(java.lang.String name)
          The author is the person who is responsible for creating the chart.
 void setChartID(int ID)
          The chart ID is set by the author(s) and should be unique in that other charts that refer to it can do so, so that end users of the chart are clearly able to follow the chart references.
 void setChartName(java.lang.String name)
          Sets the name of the chart in this JLWorksheet.
 void setDate(java.lang.String authoringDate)
          Sets the date that this chart was authored.
 void setDescription(java.lang.String footerDescription)
          The description of a JLWorksheet is a footer string that is placed at the bottom of the page, which serves to describe what is being detailed inside the flowchart.
 void setFlowCellsEnabled(boolean v)
          Either turns on or off the displaying of flow cells.
 void setJLPageType(int type)
          Deprecated. Use setJLWorksheetType(int type)
 void setJLWorksheetType(int type)
          Change between A4 or plain page formats of a JLPage in this JLWorksheet.
 void setPage(int pageNumber)
          There may be several pages in a document, and other pages may refer into these pages.
 void setProcessName(java.lang.String name)
          Within a chart there may be several processes being described in the same document.
 void setProcessNumber(int number)
          Within a chart there may be several processes being described in the same document.
 void setUI(JLWorksheetUI ui)
          Sets the UI of this JLWorksheet.
 void updateUI()
           
 
Methods inherited from class jlink.flowchart.JLPage
convertCM_TO_INCH, convertCM_TO_PIXEL, convertINCH_TO_CM, convertINCH_TO_PIXEL, convertPIXEL_TO_CM, convertPIXEL_TO_INCH, getBackground, getJLPageBorderColor, getJLPageCmHeight, getJLPageCmWidth, getJLPageHeight, getJLPageInchHeight, getJLPageInchWidth, getJLPageOrientation, getJLPageShadowColor, getJLPageSize, getJLPageSize, getJLPageType, getJLPageWidth, getMargins, isBackgroundTransparent, isBordersOn, isFocusable, isMarginsOn, isShadowsOn, setBackground, setBordersOn, setBottomMargin, setJLPageBorderColor, setJLPageHeight, setJLPageOrientation, setJLPageShadowColor, setJLPageSize, setJLPageSize, setJLPageSize, setJLPageWidth, setLeftMargin, setMargins, setMarginsOn, setRightMargin, setShadowsOn, setSize, setSize, setTopMargin, setUI, turnOffBackgroundTransparency, turnOffBorders, turnOffMargins, turnOffShadows, turnOnBackgroundTransparency, turnOnBorders, turnOnMargins, turnOnShadows
 
Methods inherited from class javax.swing.JLayeredPane
addImpl, getAccessibleContext, getComponentCountInLayer, getComponentsInLayer, getComponentToLayer, getIndexOf, getLayer, getLayer, getLayeredPaneAbove, getObjectForLayer, getPosition, highestLayer, insertIndexForLayer, isOptimizedDrawingEnabled, lowestLayer, moveToBack, moveToFront, paint, paramString, putLayer, remove, removeAll, setLayer, setLayer, setPosition
 
Methods inherited from class javax.swing.JComponent
addAncestorListener, addNotify, addVetoableChangeListener, computeVisibleRect, contains, createToolTip, disable, enable, firePropertyChange, firePropertyChange, firePropertyChange, fireVetoableChange, getActionForKeyStroke, getActionMap, getAlignmentX, getAlignmentY, getAncestorListeners, getAutoscrolls, getBaseline, getBaselineResizeBehavior, getBorder, getBounds, getClientProperty, getComponentGraphics, getComponentPopupMenu, getConditionForKeyStroke, getDebugGraphicsOptions, getDefaultLocale, getFontMetrics, getGraphics, getHeight, getInheritsPopupMenu, getInputMap, getInputMap, getInputVerifier, getInsets, getInsets, getListeners, getLocation, getMaximumSize, getMinimumSize, getNextFocusableComponent, getPopupLocation, getPreferredSize, getRegisteredKeyStrokes, getRootPane, getSize, getToolTipLocation, getToolTipText, getToolTipText, getTopLevelAncestor, getTransferHandler, getVerifyInputWhenFocusTarget, getVetoableChangeListeners, getVisibleRect, getWidth, getX, getY, grabFocus, isDoubleBuffered, isLightweightComponent, isManagingFocus, isOpaque, isPaintingForPrint, isPaintingTile, isRequestFocusEnabled, isValidateRoot, paintBorder, paintChildren, paintComponent, paintImmediately, paintImmediately, print, printAll, printBorder, printChildren, printComponent, processComponentKeyEvent, processKeyBinding, processKeyEvent, processMouseEvent, processMouseMotionEvent, putClientProperty, registerKeyboardAction, registerKeyboardAction, removeAncestorListener, removeNotify, removeVetoableChangeListener, repaint, repaint, requestDefaultFocus, requestFocus, requestFocus, requestFocusInWindow, requestFocusInWindow, resetKeyboardActions, reshape, revalidate, scrollRectToVisible, setActionMap, setAlignmentX, setAlignmentY, setAutoscrolls, setBorder, setComponentPopupMenu, setDebugGraphicsOptions, setDefaultLocale, setDoubleBuffered, setEnabled, setFocusTraversalKeys, setFont, setForeground, setInheritsPopupMenu, setInputMap, setInputVerifier, setMaximumSize, setMinimumSize, setNextFocusableComponent, setOpaque, setPreferredSize, setRequestFocusEnabled, setToolTipText, setTransferHandler, setUI, setVerifyInputWhenFocusTarget, setVisible, unregisterKeyboardAction, update
 
Methods inherited from class java.awt.Container
add, add, add, add, add, addContainerListener, addPropertyChangeListener, addPropertyChangeListener, applyComponentOrientation, areFocusTraversalKeysSet, countComponents, deliverEvent, doLayout, findComponentAt, findComponentAt, getComponent, getComponentAt, getComponentAt, getComponentCount, getComponents, getComponentZOrder, getContainerListeners, getFocusTraversalKeys, getFocusTraversalPolicy, getLayout, getMousePosition, insets, invalidate, isAncestorOf, isFocusCycleRoot, isFocusCycleRoot, isFocusTraversalPolicyProvider, isFocusTraversalPolicySet, layout, list, list, locate, minimumSize, paintComponents, preferredSize, printComponents, processContainerEvent, processEvent, remove, removeContainerListener, setComponentZOrder, setFocusCycleRoot, setFocusTraversalPolicy, setFocusTraversalPolicyProvider, setLayout, transferFocusBackward, transferFocusDownCycle, validate, validateTree
 
Methods inherited from class java.awt.Component
action, add, addComponentListener, addFocusListener, addHierarchyBoundsListener, addHierarchyListener, addInputMethodListener, addKeyListener, addMouseListener, addMouseMotionListener, addMouseWheelListener, bounds, checkImage, checkImage, coalesceEvents, contains, createImage, createImage, createVolatileImage, createVolatileImage, disableEvents, dispatchEvent, enable, enableEvents, enableInputMethods, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, getBounds, getColorModel, getComponentListeners, getComponentOrientation, getCursor, getDropTarget, getFocusCycleRootAncestor, getFocusListeners, getFocusTraversalKeysEnabled, getFont, getForeground, getGraphicsConfiguration, getHierarchyBoundsListeners, getHierarchyListeners, getIgnoreRepaint, getInputContext, getInputMethodListeners, getInputMethodRequests, getKeyListeners, getLocale, getLocation, getLocationOnScreen, getMouseListeners, getMouseMotionListeners, getMousePosition, getMouseWheelListeners, getName, getParent, getPeer, getPropertyChangeListeners, getPropertyChangeListeners, getSize, getToolkit, getTreeLock, gotFocus, handleEvent, hasFocus, hide, imageUpdate, inside, isBackgroundSet, isCursorSet, isDisplayable, isEnabled, isFocusOwner, isFocusTraversable, isFontSet, isForegroundSet, isLightweight, isMaximumSizeSet, isMinimumSizeSet, isPreferredSizeSet, isShowing, isValid, isVisible, keyDown, keyUp, list, list, list, location, lostFocus, mouseDown, mouseDrag, mouseEnter, mouseExit, mouseMove, mouseUp, move, nextFocus, paintAll, postEvent, prepareImage, prepareImage, processComponentEvent, processFocusEvent, processHierarchyBoundsEvent, processHierarchyEvent, processInputMethodEvent, processMouseWheelEvent, remove, removeComponentListener, removeFocusListener, removeHierarchyBoundsListener, removeHierarchyListener, removeInputMethodListener, removeKeyListener, removeMouseListener, removeMouseMotionListener, removeMouseWheelListener, removePropertyChangeListener, removePropertyChangeListener, repaint, repaint, repaint, resize, resize, setBounds, setBounds, setComponentOrientation, setCursor, setDropTarget, setFocusable, setFocusTraversalKeysEnabled, setIgnoreRepaint, setLocale, setLocation, setLocation, setName, show, show, size, toString, transferFocus, transferFocusUpCycle
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

chartName

protected java.lang.String chartName
The name of this flowchart.


processName

protected java.lang.String processName
The process which this chart is showing.


processNumber

protected int processNumber
The number of this process.


date

protected java.lang.String date
The date of authoring this chart.


page

protected int page
The page number of this chart.


chartID

protected int chartID
The chart ID.


author

protected java.lang.String author
The author of this chart.


description

protected java.lang.String description
The chart description to appear in the footer.


displayFlowCells

protected boolean displayFlowCells
Property detailing if the flow cells are to be displayed on the JLWorksheet. Defaults as true.

Constructor Detail

JLWorksheet

public JLWorksheet()
Method Detail

getChartName

public java.lang.String getChartName()
An author may have several different charts. In order to refer to one from another, giving a name may be of assistance.

Returns:
This chart's name.

setChartName

public void setChartName(java.lang.String name)
Sets the name of the chart in this JLWorksheet. The chart name shows in the header.

Parameters:
name - The name to set for this chart.

getProcessName

public java.lang.String getProcessName()
Within a chart there may be several processes being described in the same document. In order to refer to these processes, giving a name to them may be of assistance.

Returns:
The process name of the process being described on this worksheet.

setProcessName

public void setProcessName(java.lang.String name)
Within a chart there may be several processes being described in the same document. In order to refer to these processes, giving a name to them may be of assistance. This sets the name for a process that is in this particular JLWorksheet.

Parameters:
name - The name to set for this process.

getProcessNumber

public int getProcessNumber()
Within a chart there may be several processes being described in the same document. In order to refer to these processes, giving a unique number to them may be of assistance.

Returns:
The process number of the process being described on this worksheet.

setProcessNumber

public void setProcessNumber(int number)
Within a chart there may be several processes being described in the same document. In order to refer to these processes, giving a unique number to them may be of assistance. This method performs that function.

Parameters:
number - The number to assign to this process.

getDate

public java.lang.String getDate()
The date that this chart was authored.

Returns:
The date of authoring of this chart.

setDate

public void setDate(java.lang.String authoringDate)
Sets the date that this chart was authored.

Parameters:
authoringDate - The date of authoring.

getPage

public int getPage()
There may be several pages in a document, and other pages may refer into these pages.

Returns:
The page of this chart.

setPage

public void setPage(int pageNumber)
There may be several pages in a document, and other pages may refer into these pages. This sets a page number for a JLWorksheet so that when there are multiple pages, this can be referenced from other pages.

Parameters:
pageNumber - The number to set for this JLWorksheet page.

getChartID

public int getChartID()
The chart ID is set by the author(s) and should be unique in that other charts that refer to it can do so, so that end users of the chart are clearly able to follow the charts references.

Returns:
The chart ID.

setChartID

public void setChartID(int ID)
The chart ID is set by the author(s) and should be unique in that other charts that refer to it can do so, so that end users of the chart are clearly able to follow the chart references.

Parameters:
ID - The ID to set for the chart in this JLWorksheet.

getAuthor

public java.lang.String getAuthor()
The author is the person who is responsible for creating the chart.

Returns:
The name of the chart author.

setAuthor

public void setAuthor(java.lang.String name)
The author is the person who is responsible for creating the chart. This method sets this property.

Parameters:
name - The name of the person who authored this chart in this JLWorksheet.

getDescription

public java.lang.String getDescription()
The description of a JLWorksheet is a footer string that is placed at the bottom of the page, which serves to describe what is being detailed inside the flowchart.

Returns:
The footer description string for the JLWorksheet.

setDescription

public void setDescription(java.lang.String footerDescription)
The description of a JLWorksheet is a footer string that is placed at the bottom of the page, which serves to describe what is being detailed inside the flowchart.

Parameters:
footerDescription - The text for the footer.

isFlowCellsEnabled

public boolean isFlowCellsEnabled()
Flow cells are the boxes in a JLWorksheet that serve to hold processes in a chart. These can be either displayed or not displayed in the final product.

Returns:
true if the flow cells are to be displayed. false if they are not to be displayed.
See Also:
setFlowCellsEnabled(boolean v)

setFlowCellsEnabled

public void setFlowCellsEnabled(boolean v)
Either turns on or off the displaying of flow cells.

Parameters:
v - If true then flow cells will be displayed. If false then flow cells will not be displayed.

setJLWorksheetType

public void setJLWorksheetType(int type)
Change between A4 or plain page formats of a JLPage in this JLWorksheet.

Parameters:
type - Can only be JLPage.PAGE_A4 or JLPage.PAGE_PLAIN. Any other variable given to this method will do nothing.

setJLPageType

public void setJLPageType(int type)
Deprecated. Use setJLWorksheetType(int type)

Change between A4 or plain page formats of a JLPage in this JLWorksheet.

Overrides:
setJLPageType in class JLPage
Parameters:
type - Can only be JLPage.PAGE_A4 or JLPage.PAGE_PLAIN. Any other variable given to this method will do nothing.

setUI

public void setUI(JLWorksheetUI ui)
Sets the UI of this JLWorksheet. This takes a JLPageUI as input (a standard implementation of a page, that other more advanced page formats can emulate).

Parameters:
ui - The UI to set for this JLPage.

updateUI

public void updateUI()
Overrides:
updateUI in class JLPage

getUIClassID

public java.lang.String getUIClassID()
Returns the UI string for JLPage which is PageUI.UI_CLASS_ID

Overrides:
getUIClassID in class JLPage
Returns:
The string with information about this UI class ID.