Task.ProgressMonitor
Class ProgressMonitorUtils

java.lang.Object
  extended by Task.ProgressMonitor.ProgressMonitorUtils

public class ProgressMonitorUtils
extends java.lang.Object

ProgressMonitorUtils allows you to easily work with the progress monitor classes, to generate messages, parse information out of PropertyChangeEvents, etc.

Since:
Oct 12, 2007, 8:34:07 PM
Version:
1.0
Author:
Nazmul Idris

Nested Class Summary
static class ProgressMonitorUtils.Type
           
 
Constructor Summary
ProgressMonitorUtils()
           
 
Method Summary
static java.lang.String generateProgressMessage(ProgressMonitorUtils.Type type, java.lang.String msg, int progress, int total)
          Creates a status message for the progress, not formatted in HTML, just plain text.
static int getProgressPercent(int progress, int total)
           
static java.lang.String parseMessageFrom(java.beans.PropertyChangeEvent evt)
           
static int parsePercentFrom(java.beans.PropertyChangeEvent evt)
           
static java.lang.String parseStatusMessageFrom(java.beans.PropertyChangeEvent evt)
           
static SwingUIHookAdapter.PropertyList parseTypeFrom(java.beans.PropertyChangeEvent evt)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ProgressMonitorUtils

public ProgressMonitorUtils()
Method Detail

generateProgressMessage

public static final java.lang.String generateProgressMessage(ProgressMonitorUtils.Type type,
                                                             java.lang.String msg,
                                                             int progress,
                                                             int total)
Creates a status message for the progress, not formatted in HTML, just plain text.

Returns:
plain text string (no html formatting)

getProgressPercent

public static final int getProgressPercent(int progress,
                                           int total)

parsePercentFrom

public static int parsePercentFrom(java.beans.PropertyChangeEvent evt)

parseMessageFrom

public static java.lang.String parseMessageFrom(java.beans.PropertyChangeEvent evt)

parseTypeFrom

public static SwingUIHookAdapter.PropertyList parseTypeFrom(java.beans.PropertyChangeEvent evt)

parseStatusMessageFrom

public static java.lang.String parseStatusMessageFrom(java.beans.PropertyChangeEvent evt)


Copyright © 2011. All Rights Reserved.