|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.kuali.rice.core.api.util.RiceUtilities
public final class RiceUtilities
| Method Summary | ||
|---|---|---|
static
|
findExceptionInStack(Throwable topLevelException,
Class<T> exceptionClass)
This method searches for an exception of the specified type in the stack trace of the given exception. |
|
static String |
getFileSizeUnits(Long fileSize)
Converts a given file size in bytes to a unit of bytes, kilobyte, megabyte, or gigabyte |
|
static String |
getHostName()
|
|
static String |
getIpNumber()
|
|
static InputStream |
getResourceAsStream(String resourceLoc)
Attempts to retrieve the resource stream. |
|
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Method Detail |
|---|
public static String getIpNumber()
public static String getHostName()
public static InputStream getResourceAsStream(String resourceLoc)
throws MalformedURLException,
IOException
resourceLoc - resource location; syntax supported by DefaultResourceLoader
MalformedURLException
IOExceptionDefaultResourceLoader
public static <T extends Throwable> T findExceptionInStack(Throwable topLevelException,
Class<T> exceptionClass)
topLevelException - the exception whose stack to traverseexceptionClass - the exception class to look for
public static String getFileSizeUnits(Long fileSize)
fileSize - - size in bytes
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||