All Packages Class Hierarchy This Package Previous Next Index
Class com.sun.wizards.awt.ProgressManager
java.lang.Object
|
+----java.awt.Component
|
+----java.awt.Container
|
+----com.sun.wizards.awt.ProgressManager
- public class ProgressManager
- extends Container
The ProgressManager class contains one or more
ProgressBar objects. Each progress bar will be
labeled. The progress values will be set through
this class.
Here is the code for this applet:
import java.applet.Applet;
import java.awt.*;
import com.sun.wizards.awt.*;
public class Test extends Applet
{
public void init()
{
setLayout(new GridBagLayout());
ProgressManager progressManager = new ProgressManager(new String[] {"Progress A",
"Progress B"});
progressManager.setProgress(new int[] {82, 37});
add(progressManager);
}
}
-
labels
- The array of labels to be presented within the
ProgressManager.
-
progressBars
- The ProgressBar object to be displayed within
the ProgressManager.
-
size
- The size of the ProgressManager.
-
ProgressManager()
- Creates a ProgressManager object.
-
ProgressManager(String[])
- Creates a ProgressManager object with the
specified labels.
-
getPreferredSize()
-
Returns the preferred size of this container.
-
getProgress()
- Get the values for the progress bars.
-
setLabels(String[])
- Sets the labels and the number of progress
bars being managed by this object.
-
setProgress(int[])
- Set the values for the progress bars.
size
protected Dimension size
- The size of the ProgressManager.
labels
protected FlowLabel labels[]
- The array of labels to be presented within the
ProgressManager.
progressBars
protected ProgressBar progressBars[]
- The ProgressBar object to be displayed within
the ProgressManager.
ProgressManager
public ProgressManager()
- Creates a ProgressManager object.
ProgressManager
public ProgressManager(String labels[])
- Creates a ProgressManager object with the
specified labels. The number of labels
indicates how many progress bars are being
mananged.
The ProgressBar objects are created automatically.
- Parameters:
- labels - The progress bar labels.
getPreferredSize
public Dimension getPreferredSize()
- Returns the preferred size of this container.
- Returns:
- The preferred size of this container.
- Overrides:
- getPreferredSize in class Container
setLabels
public void setLabels(String labels[])
- Sets the labels and the number of progress
bars being managed by this object.
- Parameters:
- labels - The progress bar labels.
setProgress
public void setProgress(int progress[])
- Set the values for the progress bars.
- Parameters:
- progress - The progress values to be displayed.
getProgress
public int[] getProgress()
- Get the values for the progress bars.
- Returns:
- The progress values for all of the progress bars
this progress manager manages.
All Packages Class Hierarchy This Package Previous Next Index