| 
 | ||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectnet.sf.magicproject.management.MonitoredCheckContent
public class MonitoredCheckContent
A monitored content represents partial data representation : source, destination, content length to proceed, content proceeded length.
| Field Summary | |
|---|---|
| static int | NOTIFICATION_PERIODNotficaytion period. | 
| static java.lang.String | STR_ZIP_PATHThe string delimiting the jar/zip content. | 
| Constructor Summary | |
|---|---|
| MonitoredCheckContent(java.awt.Image content)Create a new instance of this class. | |
| MonitoredCheckContent(java.util.List<java.lang.String> localFiles,
                      java.util.List<java.lang.String> remoteFiles,
                      MonitorListener listener)Create a new instance of this class. | |
| Method Summary | |
|---|---|
|  void | acknowledgeFinished(MonitorListener listener)Unregister the specified lister from the monitored content listeners. | 
|  void | addListener(MonitorListener listener)Add a listener. | 
|  java.awt.Image | getContent()Return the current content. | 
|  boolean | isFinished()Is the whole content is got. | 
|  void | paintNotification(java.awt.Graphics g)Paint the progress bar of the content download on the given graphics. | 
|  void | run() | 
|  void | setFinished()Inidicates this content is completely loaded. | 
|  void | start()Start the download. | 
|  void | updateProgress(int contentLength,
               int currentLength)Update the content data progress. | 
| Methods inherited from class java.lang.Object | 
|---|
| equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait | 
| Field Detail | 
|---|
public static final int NOTIFICATION_PERIOD
public static final java.lang.String STR_ZIP_PATH
| Constructor Detail | 
|---|
public MonitoredCheckContent(java.awt.Image content)
content - the completed content.
public MonitoredCheckContent(java.util.List<java.lang.String> localFiles,
                             java.util.List<java.lang.String> remoteFiles,
                             MonitorListener listener)
localFiles - the destination (local) files.remoteFiles - the list of remotes files.listener - the listener to notify.| Method Detail | 
|---|
public java.awt.Image getContent()
public boolean isFinished()
public void setFinished()
public final void addListener(MonitorListener listener)
listener - the listener to add.public void paintNotification(java.awt.Graphics g)
g - the used graphics to draw our progressbar.public void acknowledgeFinished(MonitorListener listener)
listener - the listener acknowledging the finished content.public void start()
public void run()
run in interface java.lang.Runnable
public void updateProgress(int contentLength,
                           int currentLength)
contentLength - the total content length to load.currentLength - the current content length to load.| 
 | ||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||