ch.elca.el4j.util.codingsupport
Class ClassUtils

java.lang.Object
  extended by ch.elca.el4j.util.codingsupport.ClassUtils

public final class ClassUtils
extends Object

This class helps transforming a class or class related structures into a string representation.

Author:
Andreas Bur (ABU)
File-location:
ClassUtils
Last check-in date:
2009-08-04 13:59:45 +0200 (Di, 04. Aug 2009) by swismer for revision 3873

Method Summary
static String getCanonicalClassName(Class<?> clazz)
          Composes the canonical name of the given class.
static String getMethodSignature(Method method)
          Transforms the given method into a string representation.
static String getPackageName(Class<?> clazz)
          Determines the class' package name.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Method Detail

getCanonicalClassName

public static String getCanonicalClassName(Class<?> clazz)
Composes the canonical name of the given class. Arrays are transformed into the same string representation as it is needed to define them in Java (e.g. java.lang.String[][]).

Parameters:
clazz - The class which canonical name has to be computed.
Returns:
Returns the canonical name of the given class.

getPackageName

public static String getPackageName(Class<?> clazz)
Determines the class' package name.

Parameters:
clazz - The class which package name has to be determined.
Returns:
Returns the given class' package name.

getMethodSignature

public static String getMethodSignature(Method method)
Transforms the given method into a string representation.

Parameters:
method - The method to transform.
Returns:
Returns a string representation of the given method's signature.


Copyright © 2005-2011 ELCA. All Rights Reserved.