uci.util
Class Util

java.lang.Object
  |
  +--uci.util.Util

public class Util
extends Object


Method Summary
static String filenameToURI(String str)
          Fixes a platform dependent filename to standard URI form.
static URL fileToURL(File file)
           
static URL fixURLExtension(URL url, String desiredExtension)
           
protected static String imageName(String name)
           
static ImageIcon loadIconResource(String imgName)
           
static ImageIcon loadIconResource(String imgName, String desc)
           
static String stripJunk(String s)
           
static String URIToFilename(String str)
          Fixes a platform dependent filename to standard URI form.
static File URLToFile(URL url)
           
static String URLToShortName(URL url)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Method Detail

filenameToURI

public static final String filenameToURI(String str)
Fixes a platform dependent filename to standard URI form.
Parameters:
str - The string to fix.
Returns:
Returns the fixed URI string.

fileToURL

public static final URL fileToURL(File file)
                           throws MalformedURLException,
                                  IOException

fixURLExtension

public static final URL fixURLExtension(URL url,
                                        String desiredExtension)

loadIconResource

public static ImageIcon loadIconResource(String imgName)

loadIconResource

public static ImageIcon loadIconResource(String imgName,
                                         String desc)

imageName

protected static String imageName(String name)

stripJunk

public static final String stripJunk(String s)

URIToFilename

public static final String URIToFilename(String str)
Fixes a platform dependent filename to standard URI form.
Parameters:
str - The string to fix.
Returns:
Returns the fixed URI string.

URLToFile

public static final File URLToFile(URL url)
                            throws MalformedURLException

URLToShortName

public static final String URLToShortName(URL url)