xinca.components
Class XBoard

java.lang.Object
  |
  +--java.awt.Component
        |
        +--java.awt.Container
              |
              +--javax.swing.JComponent
                    |
                    +--javax.swing.JPanel
                          |
                          +--xinca.components.XBoard
All Implemented Interfaces:
javax.accessibility.Accessible, edu.gatech.coc.inca.arch.module.Accessor, edu.gatech.coc.inca.arch.constants.AttributeConstants, edu.gatech.coc.inca.arch.module.Capturer, Constants, java.awt.image.ImageObserver, java.awt.MenuContainer, java.io.Serializable

public class XBoard
extends javax.swing.JPanel
implements edu.gatech.coc.inca.arch.module.Capturer, edu.gatech.coc.inca.arch.module.Accessor, Constants

The xINCA xBoard component - a shared whiteboard.

Copyright (c) 2002 ICMC-USP.

This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation; either version 2 of the License, or (at your option) any later version.

This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.

You should have received a copy of the GNU General Public License along with this program; if not, write to the Free Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA.

Since:
JDK1.4
Author:
Renan Gonçalves Cattelan
See Also:
Serialized Form

Field Summary
 
Fields inherited from class javax.swing.JComponent
TOOL_TIP_TEXT_KEY, 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 edu.gatech.coc.inca.arch.constants.AttributeConstants
ATTRIBUTE_NAME__APPLICATION, ATTRIBUTE_NAME__APPLICATION_EVENT, ATTRIBUTE_NAME__CONTEXT_TYPE, ATTRIBUTE_NAME__DATA_TYPE, ATTRIBUTE_NAME__EVENT, ATTRIBUTE_NAME__LOCATION, ATTRIBUTE_NAME__PERSON, ATTRIBUTE_NAME__TIMESTAMP, ATTRIBUTE_VALUE__AUDIO_DATA, ATTRIBUTE_VALUE__PEOPLE_PRESENT_CONTEXT, ATTRIBUTE_VALUE__VIDEO_DATA
 
Fields inherited from interface xinca.constants.Constants
CHAT_TOKEN, DEFAULT_BOARD_HEIGHT, DEFAULT_BOARD_WIDTH, DEFAULT_INCAD_HOST, DEFAULT_SESSION_ID, DEFAULT_SLIDE_ID, DEFAULT_STROKE_ID, DEFAULT_STROKE_WIDTH, JUMP_TO_TOKEN, NEW_SLIDE_TOKEN, PROXY_PORT, RECEIVE_STROKE_TOKEN, SLIDE_FROM_IMAGE_URL_TOKEN, SOUND_TOKEN, SOUND_TRANSMISSION_PACKAGE_SIZE, THICK_STROKE, THIN_STROKE, VIDEO_TOKEN, VIDEO_TRANSMISSION_PACKAGE_SIZE, WEBLOG_TOKEN, WHITEBOARD_TOKEN
 
Fields inherited from interface java.awt.image.ImageObserver
ABORT, ALLBITS, ERROR, FRAMEBITS, HEIGHT, PROPERTIES, SOMEBITS, WIDTH
 
Constructor Summary
XBoard(int sessionID, java.lang.String username, xinca.components.XBoardListener xBoardListener, boolean captureOn, boolean accessOn)
          Constructor
XBoard(int sessionID, java.lang.String username, xinca.components.XBoardListener xBoardListener, java.awt.Dimension boardDimensions, boolean captureOn, boolean accessOn)
          Constructor
XBoard(int sessionID, java.lang.String username, xinca.components.XBoardListener xBoardListener, java.lang.String host, boolean captureOn, boolean accessOn)
          Constructor
XBoard(int sessionID, java.lang.String username, xinca.components.XBoardListener xBoardListener, java.lang.String host, int port, java.awt.Dimension boardDimensions, boolean captureOn, boolean accessOn)
          Constructor
XBoard(int sessionID, java.lang.String username, xinca.components.XBoardListener xBoardListener, java.lang.String host, int port, java.util.Vector imageVector, java.awt.Dimension boardDimensions, boolean captureOn, boolean accessOn)
          Constructor
XBoard(int sessionID, java.lang.String username, xinca.components.XBoardListener xBoardListener, java.lang.String host, java.util.Vector imageVector, boolean captureOn, boolean accessOn)
          Constructor
XBoard(int sessionID, java.lang.String username, xinca.components.XBoardListener xBoardListener, java.util.Vector imageVector, boolean captureOn, boolean accessOn)
          Constructor
XBoard(int sessionID, java.lang.String username, xinca.components.XBoardListener xBoardListener, java.util.Vector imageVector, java.awt.Dimension boardDimensions, boolean captureOn, boolean accessOn)
          Constructor
XBoard(java.lang.String username, xinca.components.XBoardListener xBoardListener, boolean captureOn, boolean accessOn)
          Constructor
XBoard(java.lang.String username, xinca.components.XBoardListener xBoardListener, java.awt.Dimension boardDimensions, boolean captureOn, boolean accessOn)
          Constructor
XBoard(java.lang.String username, xinca.components.XBoardListener xBoardListener, java.lang.String host, boolean captureOn, boolean accessOn)
          Constructor
XBoard(java.lang.String username, xinca.components.XBoardListener xBoardListener, java.lang.String host, java.awt.Dimension boardDimensions, boolean captureOn, boolean accessOn)
          Constructor
XBoard(java.lang.String username, xinca.components.XBoardListener xBoardListener, java.lang.String host, java.util.Vector imageVector, boolean captureOn, boolean accessOn)
          Constructor
XBoard(java.lang.String username, xinca.components.XBoardListener xBoardListener, java.lang.String host, java.util.Vector imageVector, java.awt.Dimension boardDimensions, boolean captureOn, boolean accessOn)
          Constructor
XBoard(java.lang.String username, xinca.components.XBoardListener xBoardListener, java.util.Vector imageVector, boolean captureOn, boolean accessOn)
          Constructor
XBoard(java.lang.String username, xinca.components.XBoardListener xBoardListener, java.util.Vector imageVector, java.awt.Dimension boardDimensions, boolean captureOn, boolean accessOn)
          Constructor
 
Method Summary
 java.awt.image.BufferedImage board2Image()
          Creates an image from the whiteboard draw area
 void clear()
          Clears the main data members of the whiteboard
 void createSlideFromImage(java.awt.Image img)
          Inserts a new slide with background into the XBoard It does not multicast the new slide through INCA
 void createSlidesFromImages(java.util.Vector imageVector)
          Creates a set of slides from pre-loaded images
 void eraseAt(int x, int y)
          Erase slide near a point
 int getCurrentSlideIndex()
          Gets the current slide index
 java.awt.Dimension getMinimumSize()
          Gets the minimum dimension of the whiteboard
 java.awt.Color getPenColor()
          Gets the pen (drawing) color
 java.awt.Dimension getPreferredSize()
          Gets the preferred dimension of the whiteboard
 int getSessionID()
          Gets the current session id
 int getStrokeWidth()
          Gets the pen thickness
 void handle(edu.gatech.coc.inca.arch.data.DataObject data_object)
          Callback method to handle a data_object this accessor is being notified of
 void handle(edu.gatech.coc.inca.arch.data.DataVector data_vector)
          Callback method to handle a data_vector this accessor is being notified of
 void handleStroke(common.data.Stroke stroke)
          Handles a stroke received by the INCA access module
 void jumpToSlide(int index)
          Jumps to a new slide
 void newSlide()
          Creates a new (blank) slide after the actual slide index position (the following slides will be one position shifted
 void newSlideAt(int index)
          Inserts a new slide
 void newSlideAt(int index, java.awt.Image image)
          Inserts a new slide with a image background
 void nextSlide()
          Changes to next slide (if there is not a next slide, a blank new one will be created)
 int numberOfSlides()
          Gets the number of slides
 void paint(java.awt.Graphics g)
          Paints the whiteboard
 void previousSlide()
          Changes to previous slide (if there is not a previous slide, nothing happens)
 void replaceSlideAt(java.awt.Image img, int index)
          Replaces a existing slide by a new one created from an image It does not multicast the new slide through INCA
 void sendStroke(common.data.Stroke stroke)
          Sends stroke through INCA
 void setEraseMode(boolean erase_state)
          Sets the pen's mode flag
 void setPenColor(java.awt.Color color)
          Sets the pen (drawing) color
 void setSessionID(int id)
          Sets the current session id
 void setStrokeWidth(int width)
          Sets the pen thickness
 void stateChanged(edu.gatech.coc.inca.arch.module.AccessModule module, boolean ready)
          Callback method to the state change of the access module
 void stateChanged(edu.gatech.coc.inca.arch.module.CaptureModule module, boolean ready)
          Callback method to the state change of the capture module
 void update()
          Updates the whiteboard
 void update(edu.gatech.coc.inca.arch.data.DataObject old_data, edu.gatech.coc.inca.arch.data.DataObject new_data)
          Callback method to indicate a update event in the capture module
 void update(java.awt.Graphics g)
          Updates the whiteboard
 boolean usingBackgroundImages()
          Indicates the use or not of background images in the slides
 
Methods inherited from class javax.swing.JPanel
getAccessibleContext, getUI, getUIClassID, setUI, updateUI
 
Methods inherited from class javax.swing.JComponent
addAncestorListener, addNotify, addPropertyChangeListener, addPropertyChangeListener, addVetoableChangeListener, computeVisibleRect, contains, createToolTip, disable, enable, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, getActionForKeyStroke, getActionMap, getAlignmentX, getAlignmentY, getAncestorListeners, getAutoscrolls, getBorder, getBounds, getClientProperty, getConditionForKeyStroke, getDebugGraphicsOptions, getDefaultLocale, getGraphics, getHeight, getInputMap, getInputMap, getInputVerifier, getInsets, getInsets, getListeners, getLocation, getMaximumSize, getNextFocusableComponent, getPropertyChangeListeners, getPropertyChangeListeners, getRegisteredKeyStrokes, getRootPane, getSize, getToolTipLocation, getToolTipText, getToolTipText, getTopLevelAncestor, getTransferHandler, getVerifyInputWhenFocusTarget, getVetoableChangeListeners, getVisibleRect, getWidth, getX, getY, grabFocus, isDoubleBuffered, isLightweightComponent, isManagingFocus, isMaximumSizeSet, isMinimumSizeSet, isOpaque, isOptimizedDrawingEnabled, isPaintingTile, isPreferredSizeSet, isRequestFocusEnabled, isValidateRoot, paintImmediately, paintImmediately, print, printAll, putClientProperty, registerKeyboardAction, registerKeyboardAction, removeAncestorListener, removeNotify, removePropertyChangeListener, removePropertyChangeListener, removeVetoableChangeListener, repaint, repaint, requestDefaultFocus, requestFocus, requestFocus, requestFocusInWindow, resetKeyboardActions, reshape, revalidate, scrollRectToVisible, setActionMap, setAlignmentX, setAlignmentY, setAutoscrolls, setBackground, setBorder, setDebugGraphicsOptions, setDefaultLocale, setDoubleBuffered, setEnabled, setFont, setForeground, setInputMap, setInputVerifier, setMaximumSize, setMinimumSize, setNextFocusableComponent, setOpaque, setPreferredSize, setRequestFocusEnabled, setToolTipText, setTransferHandler, setVerifyInputWhenFocusTarget, setVisible, unregisterKeyboardAction
 
Methods inherited from class java.awt.Container
add, add, add, add, add, addContainerListener, applyComponentOrientation, areFocusTraversalKeysSet, countComponents, deliverEvent, doLayout, findComponentAt, findComponentAt, getComponent, getComponentAt, getComponentAt, getComponentCount, getComponents, getContainerListeners, getFocusTraversalKeys, getFocusTraversalPolicy, getLayout, insets, invalidate, isAncestorOf, isFocusCycleRoot, isFocusCycleRoot, isFocusTraversalPolicySet, layout, list, list, locate, minimumSize, paintComponents, preferredSize, printComponents, remove, remove, removeAll, removeContainerListener, setFocusCycleRoot, setFocusTraversalKeys, setFocusTraversalPolicy, setLayout, transferFocusBackward, transferFocusDownCycle, validate
 
Methods inherited from class java.awt.Component
action, add, addComponentListener, addFocusListener, addHierarchyBoundsListener, addHierarchyListener, addInputMethodListener, addKeyListener, addMouseListener, addMouseMotionListener, addMouseWheelListener, bounds, checkImage, checkImage, contains, createImage, createImage, createVolatileImage, createVolatileImage, dispatchEvent, enable, enableInputMethods, getBackground, getBounds, getColorModel, getComponentListeners, getComponentOrientation, getCursor, getDropTarget, getFocusCycleRootAncestor, getFocusListeners, getFocusTraversalKeysEnabled, getFont, getFontMetrics, getForeground, getGraphicsConfiguration, getHierarchyBoundsListeners, getHierarchyListeners, getIgnoreRepaint, getInputContext, getInputMethodListeners, getInputMethodRequests, getKeyListeners, getLocale, getLocation, getLocationOnScreen, getMouseListeners, getMouseMotionListeners, getMouseWheelListeners, getName, getParent, getPeer, getSize, getToolkit, getTreeLock, gotFocus, handleEvent, hasFocus, hide, imageUpdate, inside, isBackgroundSet, isCursorSet, isDisplayable, isEnabled, isFocusable, isFocusOwner, isFocusTraversable, isFontSet, isForegroundSet, isLightweight, isShowing, isValid, isVisible, keyDown, keyUp, list, list, list, location, lostFocus, mouseDown, mouseDrag, mouseEnter, mouseExit, mouseMove, mouseUp, move, nextFocus, paintAll, postEvent, prepareImage, prepareImage, remove, removeComponentListener, removeFocusListener, removeHierarchyBoundsListener, removeHierarchyListener, removeInputMethodListener, removeKeyListener, removeMouseListener, removeMouseMotionListener, removeMouseWheelListener, repaint, repaint, repaint, resize, resize, setBounds, setBounds, setComponentOrientation, setCursor, setDropTarget, setFocusable, setFocusTraversalKeysEnabled, setIgnoreRepaint, setLocale, setLocation, setLocation, setName, setSize, setSize, show, show, size, toString, transferFocus, transferFocusUpCycle
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

XBoard

public XBoard(java.lang.String username,
              xinca.components.XBoardListener xBoardListener,
              boolean captureOn,
              boolean accessOn)
Constructor

Parameters:
username - is the username UID
xBoardListener - is the listener for the xBoard

XBoard

public XBoard(java.lang.String username,
              xinca.components.XBoardListener xBoardListener,
              java.util.Vector imageVector,
              boolean captureOn,
              boolean accessOn)
Constructor

Parameters:
username - is the username UID
xBoardListener - is the listener for the xBoard
imageVector - is the vector of background images

XBoard

public XBoard(java.lang.String username,
              xinca.components.XBoardListener xBoardListener,
              java.lang.String host,
              boolean captureOn,
              boolean accessOn)
Constructor

Parameters:
username - is the username UID
xBoardListener - is the listener for the xBoard
captureOn - is the capture On/Off flag
accessOn - is the access On/Off flag

XBoard

public XBoard(java.lang.String username,
              xinca.components.XBoardListener xBoardListener,
              java.lang.String host,
              java.util.Vector imageVector,
              boolean captureOn,
              boolean accessOn)
Constructor

Parameters:
username - is the username UID
xBoardListener - is the listener for the xBoard
imageVector - is the vector of background images
captureOn - is the capture On/Off flag
accessOn - is the access On/Off flag

XBoard

public XBoard(java.lang.String username,
              xinca.components.XBoardListener xBoardListener,
              java.awt.Dimension boardDimensions,
              boolean captureOn,
              boolean accessOn)
Constructor

Parameters:
username - is the username UID
xBoardListener - is the listener for the xBoard
boardDimensions - are the whiteboard dimensions (width and height)
captureOn - is the capture On/Off flag
accessOn - is the access On/Off flag

XBoard

public XBoard(java.lang.String username,
              xinca.components.XBoardListener xBoardListener,
              java.util.Vector imageVector,
              java.awt.Dimension boardDimensions,
              boolean captureOn,
              boolean accessOn)
Constructor

Parameters:
username - is the username UID
xBoardListener - is the listener for the xBoard
imageVector - is the vector of background images
boardDimensions - are the whiteboard dimensions (width and height)
captureOn - is the capture On/Off flag
accessOn - is the access On/Off flag

XBoard

public XBoard(java.lang.String username,
              xinca.components.XBoardListener xBoardListener,
              java.lang.String host,
              java.awt.Dimension boardDimensions,
              boolean captureOn,
              boolean accessOn)
Constructor

Parameters:
username - is the username UID
xBoardListener - is the listener for the xBoard
boardDimensions - are the whiteboard dimensions (width and height)
host - is the InCAd host
captureOn - is the capture On/Off flag
accessOn - is the access On/Off flag

XBoard

public XBoard(java.lang.String username,
              xinca.components.XBoardListener xBoardListener,
              java.lang.String host,
              java.util.Vector imageVector,
              java.awt.Dimension boardDimensions,
              boolean captureOn,
              boolean accessOn)
Constructor

Parameters:
username - is the username UID
xBoardListener - is the listener for the xBoard
imageVector - is the vector of background images
boardDimensions - are the whiteboard dimensions (width and height)
host - is the InCAd host
captureOn - is the capture On/Off flag
accessOn - is the access On/Off flag

XBoard

public XBoard(int sessionID,
              java.lang.String username,
              xinca.components.XBoardListener xBoardListener,
              boolean captureOn,
              boolean accessOn)
Constructor

Parameters:
sessionID - is the current session UID
username - is the username UID
xBoardListener - is the listener for the xBoard
captureOn - is the capture On/Off flag
accessOn - is the access On/Off flag

XBoard

public XBoard(int sessionID,
              java.lang.String username,
              xinca.components.XBoardListener xBoardListener,
              java.util.Vector imageVector,
              boolean captureOn,
              boolean accessOn)
Constructor

Parameters:
sessionID - is the current session UID
username - is the username UID
xBoardListener - is the listener for the xBoard
imageVector - is the vector of background images
captureOn - is the capture On/Off flag
accessOn - is the access On/Off flag

XBoard

public XBoard(int sessionID,
              java.lang.String username,
              xinca.components.XBoardListener xBoardListener,
              java.lang.String host,
              boolean captureOn,
              boolean accessOn)
Constructor

Parameters:
sessionID - is the current session UID
username - is the username UID
xBoardListener - is the listener for the xBoard
host - is the InCAd host
captureOn - is the capture On/Off flag
accessOn - is the access On/Off flag

XBoard

public XBoard(int sessionID,
              java.lang.String username,
              xinca.components.XBoardListener xBoardListener,
              java.lang.String host,
              java.util.Vector imageVector,
              boolean captureOn,
              boolean accessOn)
Constructor

Parameters:
sessionID - is the current session UID
username - is the username UID
xBoardListener - is the listener for the xBoard
host - is the InCAd host
imageVector - is the vector of background images
captureOn - is the capture On/Off flag
accessOn - is the access On/Off flag

XBoard

public XBoard(int sessionID,
              java.lang.String username,
              xinca.components.XBoardListener xBoardListener,
              java.awt.Dimension boardDimensions,
              boolean captureOn,
              boolean accessOn)
Constructor

Parameters:
sessionID - is the current session UID
username - is the username UID
xBoardListener - is the listener for the xBoard
boardDimensions - are the whiteboard dimensions (width and height)
captureOn - is the capture On/Off flag
accessOn - is the access On/Off flag

XBoard

public XBoard(int sessionID,
              java.lang.String username,
              xinca.components.XBoardListener xBoardListener,
              java.util.Vector imageVector,
              java.awt.Dimension boardDimensions,
              boolean captureOn,
              boolean accessOn)
Constructor

Parameters:
sessionID - is the current session UID
username - is the username UID
xBoardListener - is the listener for the xBoard
imageVector - is the vector of background images
boardDimensions - are the whiteboard dimensions (width and height)
captureOn - is the capture On/Off flag
accessOn - is the access On/Off flag

XBoard

public XBoard(int sessionID,
              java.lang.String username,
              xinca.components.XBoardListener xBoardListener,
              java.lang.String host,
              int port,
              java.awt.Dimension boardDimensions,
              boolean captureOn,
              boolean accessOn)
Constructor

Parameters:
sessionID - is the current session UID
username - is the username UID
xBoardListener - is the listener for the xBoard
host - is the InCAd host
port - is the InCAd port
boardDimensions - are the whiteboard dimensions (width and height)
captureOn - is the capture On/Off flag
accessOn - is the access On/Off flag

XBoard

public XBoard(int sessionID,
              java.lang.String username,
              xinca.components.XBoardListener xBoardListener,
              java.lang.String host,
              int port,
              java.util.Vector imageVector,
              java.awt.Dimension boardDimensions,
              boolean captureOn,
              boolean accessOn)
Constructor

Parameters:
sessionID - is the current session UID
username - is the username UID
xBoardListener - is the listener for the xBoard
host - is the InCAd host
port - is the InCAd port
imageVector - is the vector of background images
boardDimensions - are the whiteboard dimensions (width and height)
captureOn - is the capture On/Off flag
accessOn - is the access On/Off flag
Method Detail

getSessionID

public int getSessionID()
Gets the current session id

Returns:
the session UID

setSessionID

public void setSessionID(int id)
Sets the current session id


getCurrentSlideIndex

public int getCurrentSlideIndex()
Gets the current slide index

Returns:
the current slide index

numberOfSlides

public int numberOfSlides()
Gets the number of slides

Returns:
the number of slides

setEraseMode

public void setEraseMode(boolean erase_state)
Sets the pen's mode flag

Parameters:
erase_state - is the boolean pen's mode (false for pen and true for erase)

getPenColor

public java.awt.Color getPenColor()
Gets the pen (drawing) color

Returns:
the current drawing color

setPenColor

public void setPenColor(java.awt.Color color)
Sets the pen (drawing) color

Parameters:
color - is the current drawing color

getStrokeWidth

public int getStrokeWidth()
Gets the pen thickness

Returns:
the pen thickness

setStrokeWidth

public void setStrokeWidth(int width)
Sets the pen thickness


usingBackgroundImages

public boolean usingBackgroundImages()
Indicates the use or not of background images in the slides

Returns:
true if at least one of the slides have a background image, and false otherwise

handleStroke

public void handleStroke(common.data.Stroke stroke)
Handles a stroke received by the INCA access module

Parameters:
stroke - is the stroke to handle

sendStroke

public void sendStroke(common.data.Stroke stroke)
Sends stroke through INCA

Parameters:
stroke - is the Stroke to send

createSlidesFromImages

public void createSlidesFromImages(java.util.Vector imageVector)
Creates a set of slides from pre-loaded images

Parameters:
imageVector - is the vector with the pre-loaded images

createSlideFromImage

public void createSlideFromImage(java.awt.Image img)
Inserts a new slide with background into the XBoard It does not multicast the new slide through INCA

Parameters:
img - is the new slide's background image

replaceSlideAt

public void replaceSlideAt(java.awt.Image img,
                           int index)
Replaces a existing slide by a new one created from an image It does not multicast the new slide through INCA

Parameters:
img - is the new slide's background image
index - is where to insert the new slide

board2Image

public java.awt.image.BufferedImage board2Image()
Creates an image from the whiteboard draw area

Returns:
an image representing the whiteboard canvas

update

public void update()
Updates the whiteboard


update

public void update(java.awt.Graphics g)
Updates the whiteboard

Overrides:
update in class javax.swing.JComponent
Parameters:
g - is the Graphics object to use to paint with

paint

public void paint(java.awt.Graphics g)
Paints the whiteboard

Overrides:
paint in class javax.swing.JComponent
Parameters:
g - is the Graphics object to use to paint with

getPreferredSize

public java.awt.Dimension getPreferredSize()
Gets the preferred dimension of the whiteboard

Overrides:
getPreferredSize in class javax.swing.JComponent
Returns:
the preferred Dimension

getMinimumSize

public java.awt.Dimension getMinimumSize()
Gets the minimum dimension of the whiteboard

Overrides:
getMinimumSize in class javax.swing.JComponent
Returns:
the minimum Dimension

eraseAt

public void eraseAt(int x,
                    int y)
Erase slide near a point

Parameters:
x - is the int value X coordinate where to erase
y - is the int value Y coordinate where to erase

nextSlide

public void nextSlide()
Changes to next slide (if there is not a next slide, a blank new one will be created)


previousSlide

public void previousSlide()
Changes to previous slide (if there is not a previous slide, nothing happens)


newSlide

public void newSlide()
Creates a new (blank) slide after the actual slide index position (the following slides will be one position shifted


newSlideAt

public void newSlideAt(int index)
Inserts a new slide

Parameters:
index - is the position where to insert the new slide

newSlideAt

public void newSlideAt(int index,
                       java.awt.Image image)
Inserts a new slide with a image background

Parameters:
index - is the position where to insert the new slide
image - is the image to use as background

jumpToSlide

public void jumpToSlide(int index)
Jumps to a new slide

Parameters:
index - is the index of the slide to jump to

stateChanged

public void stateChanged(edu.gatech.coc.inca.arch.module.CaptureModule module,
                         boolean ready)
Callback method to the state change of the capture module

Specified by:
stateChanged in interface edu.gatech.coc.inca.arch.module.Capturer
Parameters:
module - is the capture module
ready - is the boolean state of the capture module

update

public void update(edu.gatech.coc.inca.arch.data.DataObject old_data,
                   edu.gatech.coc.inca.arch.data.DataObject new_data)
Callback method to indicate a update event in the capture module

Specified by:
update in interface edu.gatech.coc.inca.arch.module.Accessor
Parameters:
old_data - is the old DataObject
new_data - is the updated DataObject

stateChanged

public void stateChanged(edu.gatech.coc.inca.arch.module.AccessModule module,
                         boolean ready)
Callback method to the state change of the access module

Specified by:
stateChanged in interface edu.gatech.coc.inca.arch.module.Accessor
Parameters:
module - is the access module
ready - is the boolean state of the access module

handle

public void handle(edu.gatech.coc.inca.arch.data.DataObject data_object)
Callback method to handle a data_object this accessor is being notified of

Parameters:
data_object - is the DataObject to handle

handle

public void handle(edu.gatech.coc.inca.arch.data.DataVector data_vector)
Callback method to handle a data_vector this accessor is being notified of

Specified by:
handle in interface edu.gatech.coc.inca.arch.module.Accessor
Parameters:
data_vector - is the DataVector to handle

clear

public void clear()
Clears the main data members of the whiteboard