org.argouml.persistence
Class ProgressEvent
java.lang.Object
java.util.EventObject
org.argouml.persistence.ProgressEvent
- All Implemented Interfaces:
- Serializable
- public class ProgressEvent
- extends EventObject
An event to be fired in order to tell some other listener of progress
through some activity.
- See Also:
- Serialized Form
Constructor Summary |
ProgressEvent(Object source,
long thePosition,
long theLength)
Constructor for a new ProgressEvent |
ProgressEvent(Object source,
long thePosition,
long theLength,
String theDescription)
Constructor for a new ProgressEvent |
Method Summary |
long |
getDescription()
An potional description of progress. |
long |
getLength()
Return the length that progress is measuring. |
long |
getPosition()
Return the position of progress as a proportion of length. |
length
private long length
position
private long position
description
private String description
ProgressEvent
public ProgressEvent(Object source,
long thePosition,
long theLength)
- Constructor for a new ProgressEvent
- Parameters:
source
- the source that generated this eventthePosition
- the position to which progress has reach as a
proportion of lengththeLength
- the total length the progress is measuring
ProgressEvent
public ProgressEvent(Object source,
long thePosition,
long theLength,
String theDescription)
- Constructor for a new ProgressEvent
- Parameters:
source
- the source that generated this eventthePosition
- the position to which progress has reach as a
proportion of lengththeLength
- the total length the progress is measuringtheDescription
- a text description of progress
getPosition
public long getPosition()
- Return the position of progress as a proportion of length.
- Returns:
- progress position.
getLength
public long getLength()
- Return the length that progress is measuring. Typically this is the
length of a file or 100 if percentage progress is being measured.
- Returns:
- progress length.
getDescription
public long getDescription()
- An potional description of progress. The GUI should replace any existing
progress description it displays if it find that this is non-null.
- Returns:
- progress description or null if no change.