org.globus.cog.gridface.impl.desktop.util
Class DesktopUtilities

java.lang.Object
  extended byorg.globus.cog.gridface.impl.desktop.util.DesktopUtilities

public class DesktopUtilities
extends Object


Nested Class Summary
static class DesktopUtilities.DarkenImage
           
static class DesktopUtilities.GrayFilter
           
static class DesktopUtilities.SplashWindow
           
 
Field Summary
static String GLOBUS_HOME
           
 
Constructor Summary
DesktopUtilities()
           
 
Method Summary
static boolean checkGridProyInfo()
           
static String convertFileNametoExternalForm(String fileName)
           
static AbstractIcon createIcon(String applicationClass, ObjectPair arguments, String text, String iconType, String iconImage)
           
static Object createObject(Constructor constructor, Object[] arguments)
           
static TableColumn findTableColumn(JTable table, int columnModelIndex)
           
static Point fitIconInBounds(AbstractIcon icon, Rectangle bounds, int xLoc, int yLoc)
           
static File getDestinationFile(String startLoc, String dotExtention, String dialogTitle)
           
static JMenu getMenu(String name, JMenuBar menuBar)
           
static String getPlatformCommandString()
           
static File getSourceFile(String startLoc, String dotExtention, String dialogTitle)
           
static String getStringFromFile(String fileName)
           
static ImageIcon getSystemIconForFile(String execFileName)
           
static boolean isLinuxPlatform()
           
static boolean isWindows9xPlatform()
           
static boolean isWindowsNTBasedPlatform()
           
static boolean isWindowsPlatform()
           
static String listToString(List list, String delimeter)
           
static boolean loadRSLToIconAttributes(String rslFileName, DesktopIcon icon)
           
static void makeCompactGrid(Container parent, int rows, int cols, int initialX, int initialY, int xPad, int yPad)
           
static ImageIcon makeIconDark(ImageIcon icon)
           
static ImageIcon makeIconGray(ImageIcon icon)
           
static int optionConfirmation(Component sourceComp, String confirmString, String closeTitle, int optionType)
           
static void showCoGSetup()
           
static void showCreateCoGSetup(JFrame container, Action closeAction)
          Customized version of the setup that calls closeAction.actionPerformed upon completion
static void showCreateGridProxy(JFrame container, boolean modal)
           
static void showDestroyGridProxy(JFrame container)
           
static void showGridProxyInfo(JFrame container)
           
static void showSplashWindow(String imageURI, Frame f, int waitTime)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

GLOBUS_HOME

public static final String GLOBUS_HOME
Constructor Detail

DesktopUtilities

public DesktopUtilities()
Method Detail

getStringFromFile

public static String getStringFromFile(String fileName)
                                throws IOException
Throws:
IOException

loadRSLToIconAttributes

public static boolean loadRSLToIconAttributes(String rslFileName,
                                              DesktopIcon icon)
                                       throws FileNotFoundException,
                                              IOException
Throws:
FileNotFoundException
IOException

listToString

public static String listToString(List list,
                                  String delimeter)

createIcon

public static AbstractIcon createIcon(String applicationClass,
                                      ObjectPair arguments,
                                      String text,
                                      String iconType,
                                      String iconImage)
                               throws Exception
Throws:
Exception

createObject

public static Object createObject(Constructor constructor,
                                  Object[] arguments)
                           throws Exception
Throws:
Exception

getSystemIconForFile

public static ImageIcon getSystemIconForFile(String execFileName)

optionConfirmation

public static int optionConfirmation(Component sourceComp,
                                     String confirmString,
                                     String closeTitle,
                                     int optionType)

makeIconDark

public static ImageIcon makeIconDark(ImageIcon icon)

makeIconGray

public static ImageIcon makeIconGray(ImageIcon icon)

makeCompactGrid

public static void makeCompactGrid(Container parent,
                                   int rows,
                                   int cols,
                                   int initialX,
                                   int initialY,
                                   int xPad,
                                   int yPad)

findTableColumn

public static TableColumn findTableColumn(JTable table,
                                          int columnModelIndex)

getMenu

public static JMenu getMenu(String name,
                            JMenuBar menuBar)

getSourceFile

public static File getSourceFile(String startLoc,
                                 String dotExtention,
                                 String dialogTitle)

getDestinationFile

public static File getDestinationFile(String startLoc,
                                      String dotExtention,
                                      String dialogTitle)

isWindows9xPlatform

public static boolean isWindows9xPlatform()

isWindowsNTBasedPlatform

public static boolean isWindowsNTBasedPlatform()

isWindowsPlatform

public static boolean isWindowsPlatform()

isLinuxPlatform

public static boolean isLinuxPlatform()

getPlatformCommandString

public static String getPlatformCommandString()

convertFileNametoExternalForm

public static String convertFileNametoExternalForm(String fileName)

fitIconInBounds

public static Point fitIconInBounds(AbstractIcon icon,
                                    Rectangle bounds,
                                    int xLoc,
                                    int yLoc)

showSplashWindow

public static void showSplashWindow(String imageURI,
                                    Frame f,
                                    int waitTime)

showCoGSetup

public static void showCoGSetup()

checkGridProyInfo

public static boolean checkGridProyInfo()

showCreateGridProxy

public static void showCreateGridProxy(JFrame container,
                                       boolean modal)

showCreateCoGSetup

public static void showCreateCoGSetup(JFrame container,
                                      Action closeAction)
Customized version of the setup that calls closeAction.actionPerformed upon completion

Parameters:
container - -
closeAction - - an action to do after closing the window

showDestroyGridProxy

public static void showDestroyGridProxy(JFrame container)

showGridProxyInfo

public static void showGridProxyInfo(JFrame container)