javafx.reflect
Class LocalReflectionContext

java.lang.Object
  extended by javafx.reflect.ReflectionContext
      extended by javafx.reflect.LocalReflectionContext

public class LocalReflectionContext
extends ReflectionContext

Implementation of ReflectionContext using Java reflection. Can only access objects and types in the current JVM. Normally, this is a singleton, though in the future there might be variants with different class search paths (similar to com.sun.jdi.PathSearchingVirtualMachine).


Field Summary
 
Fields inherited from class javafx.reflect.ReflectionContext
FXOBJECT_NAME, INTERFACE_SUFFIX
 
Method Summary
 ClassRef findClass(java.lang.String cname)
          Get the ClassRef for the class with the given name.
 ClassRef findClass(java.lang.String cname, java.lang.ClassLoader loader)
          Get the ClassRef for the class with the given name.
static LocalReflectionContext getInstance()
          Get the default instance.
 TypeRef getIntegerType()
          Get the run-time representation of the JavaXF Integer type.
 TypeRef getNumberType()
          Get the run-time representation of the JavaXF Number type.
 ClassRef makeClassRef(java.lang.Class cls)
          Create a reference to a given Class.
 ObjectRef makeObjectRef(java.lang.Object obj)
          Create a reference to a given Object.
 SequenceBuilder makeSequenceBuilder(TypeRef elementType)
          Create a helper object for building a sequence value.
 
Methods inherited from class javafx.reflect.ReflectionContext
getAnyType, makeSequence
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Method Detail

getInstance

public static LocalReflectionContext getInstance()
Get the default instance.


makeObjectRef

public ObjectRef makeObjectRef(java.lang.Object obj)
Create a reference to a given Object.


findClass

public ClassRef findClass(java.lang.String cname)
Get the ClassRef for the class with the given name.

Specified by:
findClass in class ReflectionContext

findClass

public ClassRef findClass(java.lang.String cname,
                          java.lang.ClassLoader loader)
Get the ClassRef for the class with the given name.


makeClassRef

public ClassRef makeClassRef(java.lang.Class cls)
Create a reference to a given Class.


makeSequenceBuilder

public SequenceBuilder makeSequenceBuilder(TypeRef elementType)
Description copied from class: ReflectionContext
Create a helper object for building a sequence value.

Specified by:
makeSequenceBuilder in class ReflectionContext

getIntegerType

public TypeRef getIntegerType()
Description copied from class: ReflectionContext
Get the run-time representation of the JavaXF Integer type.

Specified by:
getIntegerType in class ReflectionContext

getNumberType

public TypeRef getNumberType()
Description copied from class: ReflectionContext
Get the run-time representation of the JavaXF Number type.

Specified by:
getNumberType in class ReflectionContext