Class IFComponent

java.lang.Object
   |
   +----java.awt.Component
           |
           +----java.awt.Container
                   |
                   +----com.sun.java.swing.JComponent
                           |
                           +----com.sun.java.swing.JPanel
                                   |
                                   +----IFComponent

public abstract class IFComponent
extends JPanel
abstract root class from which all IFComponents must be derived. IFComponents are graphical interface components associated with an Apache option.

Author:
Patrice Bensoussan, Thierry Bensoussan

Variable Index

 o box
 o boxHash
 o dataHash
 o defaultFont
 o fileToGenerate
 o key

Constructor Index

 o IFComponent()
Default constructor

Method Index

 o apply(String)
generate configuration files corresponding to this component
 o init()
initialize the component with its defaults state
 o isSelected()
get the state of the component
 o load(BufferedReader)
loads a new instance of data
 o newData(String)
create a new instance of data in this object
 o removeData(String)
remove a specific instance in this component
 o removeFile(String)
deletes the file which must be generated
 o save(PrintWriter)
saves the current instance of this components
 o setFilename(String)
sets the name of the file which must be generated
 o setGenerate(String, String)
set the strings to generate
 o setSelected(boolean)
set the state of the component
 o storeData()
store the currenty used data in this component
 o useData(String)
use a specific instance in this component

Variables

 o box
 protected JCheckBox box
 o defaultFont
 protected static Font defaultFont
 o fileToGenerate
 protected String fileToGenerate
 o dataHash
 protected Hashtable dataHash
 o boxHash
 protected Hashtable boxHash
 o key
 protected String key

Constructors

 o IFComponent
 public IFComponent()
Default constructor

Methods

 o init
 public void init()
initialize the component with its defaults state

 o apply
 public abstract void apply(String dir)
generate configuration files corresponding to this component

 o setGenerate
 public abstract void setGenerate(String head,
                                  String tail)
set the strings to generate

 o newData
 public void newData(String key)
create a new instance of data in this object

 o useData
 public void useData(String key)
use a specific instance in this component

 o storeData
 public void storeData()
store the currenty used data in this component

 o removeData
 public void removeData(String key)
remove a specific instance in this component

 o setFilename
 public void setFilename(String file)
sets the name of the file which must be generated

 o removeFile
 public void removeFile(String dir)
deletes the file which must be generated

 o isSelected
 public boolean isSelected()
get the state of the component

Returns:
the state of the component indicating if it should be used when applying the config
 o setSelected
 public void setSelected(boolean state)
set the state of the component

Parameters:
state - boolean value indicating if the component should be used when applying the config
 o save
 public abstract void save(PrintWriter out)
saves the current instance of this components

 o load
 public abstract void load(BufferedReader in)
loads a new instance of data