com.bff.utils
Class Utils

java.lang.Object
  extended by com.bff.utils.Utils

public class Utils
extends java.lang.Object


Constructor Summary
Utils()
           
 
Method Summary
static int autoResizeTable(javax.swing.JTable aTable, boolean includeColumnHeaderWidth)
           
static int autoResizeTable(javax.swing.JTable aTable, boolean includeColumnHeaderWidth, int columnPadding)
           
static void centerInParent(java.awt.Component component, java.awt.Frame parent)
           
static java.lang.String convertTime(long time)
           
static java.lang.String formatTime(long seconds)
           
static java.awt.Cursor getHourglassCursor()
           
static java.awt.Cursor getNormalCursor()
           
static javax.swing.JFrame getParentComponent(java.awt.Component component)
           
static java.awt.Image loadImage(java.io.InputStream inStream)
          Loads an ImageIcon object from this archive.
static void readFile(javax.swing.JTextArea textArea, java.io.File file)
           
static void sizeAllColumnsToFitData(javax.swing.JTable table)
           
static void sizeAllColumnsToFitData(javax.swing.JTable table, int padding)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

Utils

public Utils()
Method Detail

sizeAllColumnsToFitData

public static void sizeAllColumnsToFitData(javax.swing.JTable table)

sizeAllColumnsToFitData

public static void sizeAllColumnsToFitData(javax.swing.JTable table,
                                           int padding)

getParentComponent

public static javax.swing.JFrame getParentComponent(java.awt.Component component)

formatTime

public static java.lang.String formatTime(long seconds)

convertTime

public static final java.lang.String convertTime(long time)

readFile

public static void readFile(javax.swing.JTextArea textArea,
                            java.io.File file)

centerInParent

public static void centerInParent(java.awt.Component component,
                                  java.awt.Frame parent)

getHourglassCursor

public static java.awt.Cursor getHourglassCursor()

getNormalCursor

public static java.awt.Cursor getNormalCursor()

autoResizeTable

public static int autoResizeTable(javax.swing.JTable aTable,
                                  boolean includeColumnHeaderWidth)

autoResizeTable

public static int autoResizeTable(javax.swing.JTable aTable,
                                  boolean includeColumnHeaderWidth,
                                  int columnPadding)

loadImage

public static java.awt.Image loadImage(java.io.InputStream inStream)
Loads an ImageIcon object from this archive. Note: This method is compatible under Java Web Start.

Parameters:
name - the name of the icon file
Returns:
the icon if loaded, null otherwise