org.jboss.remoting.loading
Class ClassUtil

java.lang.Object
  extended byorg.jboss.remoting.loading.ClassUtil

public class ClassUtil
extends Object

ClassUtil is a set of generic class utlities.

Version:
$Revision: 1.2 $
Author:
Jeff Haynie

Constructor Summary
ClassUtil()
           
 
Method Summary
static Object deserialize(byte[] buf)
           
static Object deserialize(byte[] buf, ClassLoader cl)
           
static Object deserialize(ClassBytes cb, ClassLoader cl)
           
static String getArrayClassPart(String className)
           
static Class[] getInterfacesFor(Class clazz)
          given a class, recurse its dependency graph and find all its implemented interfaces
static String getPackageName(Class cl)
           
static String getShortClassName(Class cl)
           
static boolean isArrayClass(String className)
           
static byte[] serialize(Object obj)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ClassUtil

public ClassUtil()
Method Detail

deserialize

public static Object deserialize(ClassBytes cb,
                                 ClassLoader cl)
                          throws IOException,
                                 ClassNotFoundException
Throws:
IOException
ClassNotFoundException

deserialize

public static Object deserialize(byte[] buf)
                          throws IOException,
                                 ClassNotFoundException
Throws:
IOException
ClassNotFoundException

deserialize

public static Object deserialize(byte[] buf,
                                 ClassLoader cl)
                          throws IOException,
                                 ClassNotFoundException
Throws:
IOException
ClassNotFoundException

serialize

public static byte[] serialize(Object obj)
                        throws IOException
Throws:
IOException

isArrayClass

public static boolean isArrayClass(String className)

getArrayClassPart

public static String getArrayClassPart(String className)

getPackageName

public static String getPackageName(Class cl)

getShortClassName

public static String getShortClassName(Class cl)

getInterfacesFor

public static Class[] getInterfacesFor(Class clazz)
given a class, recurse its dependency graph and find all its implemented interfaces

Parameters:
clazz -
Returns:
array of interfaces


Copyright © 2002 JBoss Group, LLC. All Rights Reserved.