Package com.dassault_systemes.catweb.base.catlet

   
Class JCATletAbstract

 
Class Hierarchy
java.lang.Object
  |
  +-java.awt.Component
        |
        +-java.awt.Container
              |
              +-javax.swing.JComponent
                    |
                    +-javax.swing.JPanel
                          |
                          +-com.dassault_systemes.catweb.base.swing.CATJPanel
                                |
                                +-com.dassault_systemes.catweb.base.awt.ToolbarContainer
                                      |
                                      +-com.dassault_systemes.catweb.base.catlet.JCATletAbstract
Class Location

Framework : JApplicationFrame

Module : GW0Kernel

Class Description

public abstract class JCATletAbstract

Abstract Swing implementation of the ICATlet interface.

   All Implemented Interfaces:
ICATlet
CursorListener
SettingChangeListener
See Also:
com.dassault_systemes.catweb.base.catlet.ICATlet
Field Summary
protected boolean displayWorkshops
protected boolean firstActivation
protected boolean isActivated
for activation state
public static final Integer VERSION_2
protected Vector viewersWorkshop
protected ViewInterface[] views
The views of MVC

Constructor Summary
JCATletAbstract()
Default constructor.
JCATletAbstract(boolean workareaInScrollpane)
Constructor.

Method Summary
protected abstract void activate()
Called when the catlet is activated.
public void addNotify()
If a CATlet is added inside a container and is not activated yet, do it This let the CATlet autoactivate itself in a desktop-less environment
public boolean askStop()
protected abstract void deactivate()
Called when the catlet is deactivated This method is not directly called by the Frame but by the doDeactivate() method Users should put functionnalities related to deactivation in this method
protected void displayWorkshops()
Display the workshops of the catlet and its viewers in the toolbars and menubar
public void doActivate()
method called by the Frame to activate the catlet.
public void doCleanup()
Called by the WebTop to clean the CATlet.
public final void doDeactivate()
method called by the Frame to deactivate the catlet.
public void finalize()
public final String getCATletName()
Returns the CATlet name.
public CommandSelector getCommandSelector()
Returns the CommandSelector object that handle the life cycle of this CATlet attached Commands
public CSO getCSO()
Returns the CSO that handle selection for this CATlet.
public String getCurrentDocumentName()
Returns the name of the current Document of the CATlet
public int getHelpID()
Returns an Id that will be used to retreive the help for this CATlet By default, this methods returns -1
public String getName()
Returns the CATlet name.
public final Integer getVersion()
public ViewInterface getView()
Returns the CATlet main view
public String getWorkshopFilename()
returns the file name that will be used for the workshop description of this catlet
public boolean isActivated()
returns the activation state of the CATlet
public boolean isFocusTraversable()
public final void setCATletName(String name)
Set the name of this catlet.
public void setCurrentDocumentName(String name)
Sets the name of the current document of the CATlet.
public void setName(String name)
Calls setCATletName method and catch PropertyVetoException
public void setVisible(boolean isVisible)
public void setWorkshopFilename(String name)
Sets the file name that will be used for the workshop description of this catlet
public void start()
public void stop()


Field Detail

displayWorkshops

    protected boolean displayWorkshops


firstActivation

    protected boolean firstActivation


isActivated

    protected boolean isActivated
for activation state


VERSION_2

    public static final Integer VERSION_2


viewersWorkshop

    protected Vector viewersWorkshop


views

    protected ViewInterface[] views
The views of MVC


Constructor Detail

JCATletAbstract

    JCATletAbstract()

Default constructor. The workarea is contained inside a scrollpane


JCATletAbstract

    JCATletAbstract(boolean workareaInScrollpane)

Constructor. Flag let you choose in what is contained the workarea. If set to true workarea is contained inside a JScrollpane. If set to false, workarea is contained inside a JPanel.

Parameters:
workareaInScrollpane
- specified if the workarea is in a scrollpane or not

Method Detail

activate

    protected abstract void activate()

Called when the catlet is activated. This method is not directly called by the Frame but by the doActivate() method Users should put functionnalities related to activation in this method

See Also:
com.dassault_systemes.catweb.base.catlet.JCATlet#doActivate()

addNotify

    public void addNotify()

If a CATlet is added inside a container and is not activated yet, do it This let the CATlet autoactivate itself in a desktop-less environment


askStop

    public boolean askStop()


deactivate

    protected abstract void deactivate()

Called when the catlet is deactivated This method is not directly called by the Frame but by the doDeactivate() method Users should put functionnalities related to deactivation in this method

See Also:
com.dassault_systemes.catweb.base.catlet.JCATlet#doDeactivate()

displayWorkshops

    protected void displayWorkshops()

Display the workshops of the catlet and its viewers in the toolbars and menubar


doActivate

    public void doActivate()

method called by the Frame to activate the catlet. Implemented final. If activation is needed, the method activate() is called

See Also:
com.dassault_systemes.catweb.base.catlet.JCATlet#activate()

doCleanup

    public void doCleanup()

Called by the WebTop to clean the CATlet. Implemented final. Application must overload the cleanup() method if they have objects to clean. this method calls cleanup() method.

See Also:
com.dassault_systemes.catweb.base.catlet.ICATlet#cleanup()

doDeactivate

    public final void doDeactivate()

method called by the Frame to deactivate the catlet. Implemented final. If deactivation is needed, the method deactivate() is called

See Also:
com.dassault_systemes.catweb.base.catlet.JCATlet#deactivate()

finalize

    public void finalize()


getCATletName

    public final String getCATletName()

Returns the CATlet name. If no name has been provided, then the display name of the BeanDescriptor will be returned. If no BeanDescriptor is provided, the name "CATlet" is returned instead

Return:
the name of the CATlet

getCommandSelector

    public CommandSelector getCommandSelector()

Returns the CommandSelector object that handle the life cycle of this CATlet attached Commands

See Also:
com.dassault_systemes.catweb.base.catlet.CommandSelector
com.dassault_systemes.catweb.base.catlet.command.Command

getCSO

    public CSO getCSO()

Returns the CSO that handle selection for this CATlet. The CSO object is only instanciated on first demand


getCurrentDocumentName

    public String getCurrentDocumentName()

Returns the name of the current Document of the CATlet

Return:
the name of the current document

getHelpID

    public int getHelpID()

Returns an Id that will be used to retreive the help for this CATlet By default, this methods returns -1


getName

    public String getName()

Returns the CATlet name. this method call getCATletName method.

Return:
the CATlet name
See Also:
com.dassault_systemes.catweb.base.catlet.JCATlet#getCATletName()

getVersion

    public final Integer getVersion()


getView

    public ViewInterface getView()

Returns the CATlet main view

See Also:
com.dassault_systemes.catweb.base.catlet.view.ViewInterface

getWorkshopFilename

    public String getWorkshopFilename()

returns the file name that will be used for the workshop description of this catlet

Return:
the file name of the CATlet workshop

isActivated

    public boolean isActivated()

returns the activation state of the CATlet

Return:
true if activated, false otherwise

isFocusTraversable

    public boolean isFocusTraversable()


setCATletName

    public final void setCATletName(String name)

Set the name of this catlet. The CATlet name is a vetoable property. Each time the catlet name is modified, a propertyChangeEvent is fired. If you want to veto this property, you must subscribe on addVetoableListener otherwise, if you just want to be warned, subscribe on addPropertyChangeListener

Parameters:
name
- the new name of the CATlet
Throws:
PropertyVetoException - If the new name is rejected
See Also:
java.beans.VetoableChangeListener
java.beans.PropertyChangeListener

setCurrentDocumentName

    public void setCurrentDocumentName(String name)

Sets the name of the current document of the CATlet. this name is displayed by the webtop in the taskbar

Parameters:
display
name of the current document

setName

    public void setName(String name)

Calls setCATletName method and catch PropertyVetoException

Parameters:
new
name of the CATlet
See Also:
com.dassault_systemes.catweb.base.catlet.JCATlet#setCATletName(String name)

setVisible

    public void setVisible(boolean isVisible)


setWorkshopFilename

    public void setWorkshopFilename(String name)

Sets the file name that will be used for the workshop description of this catlet

Parameters:
the
file name of the CATlet workshop

start

    public void start()


stop

    public void stop()



Copyright © 2000, Dassault Systèmes. All rights reserved