byucc.jhdl.apps.util
Class Reflection

java.lang.Object
  extended bybyucc.jhdl.apps.util.Reflection

public class Reflection
extends java.lang.Object

Class to assist in the some of the reflection work done by classes such as Stimulator and DynamicTestBench

Author:
Anthony L. Slade

Constructor Summary
Reflection()
           
 
Method Summary
static java.lang.Object instancePrimitive(java.lang.Class type, java.lang.String value)
          Determines if the given class is of any of the Java primitive types (boolean, int, long, etc.) and attempts to instance a representative object (Boolean, Integer, Long, etc.) based on the value given.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

Reflection

public Reflection()
Method Detail

instancePrimitive

public static java.lang.Object instancePrimitive(java.lang.Class type,
                                                 java.lang.String value)
                                          throws java.lang.ClassNotFoundException,
                                                 java.lang.NoSuchMethodException,
                                                 java.lang.InstantiationException,
                                                 java.lang.reflect.InvocationTargetException
Determines if the given class is of any of the Java primitive types (boolean, int, long, etc.) and attempts to instance a representative object (Boolean, Integer, Long, etc.) based on the value given.

Parameters:
type - the class of the primitive to instance
value - the value to give to the new instance
Throws:
java.lang.ClassNotFoundException
java.lang.NoSuchMethodException
java.lang.InstantiationException
java.lang.reflect.InvocationTargetException


Copyright ? 2006 Brigham Young University, Configurable Computing Laboratory. All Rights Reserved.