org.hibernate.test.dynamicentity
Class DataProxyHandler

java.lang.Object
  extended by org.hibernate.test.dynamicentity.DataProxyHandler
All Implemented Interfaces:
InvocationHandler

public final class DataProxyHandler
extends Object
implements InvocationHandler

A simple InvocationHandler to act as the handler for our generated Proxy-based entity instances.

This is a trivial impl which simply keeps the property values into a Map.


Constructor Summary
DataProxyHandler(String entityName, Serializable id)
           
 
Method Summary
 HashMap getData()
           
 String getEntityName()
           
 Object invoke(Object proxy, Method method, Object[] args)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

DataProxyHandler

public DataProxyHandler(String entityName,
                        Serializable id)
Method Detail

invoke

public Object invoke(Object proxy,
                     Method method,
                     Object[] args)
              throws Throwable
Specified by:
invoke in interface InvocationHandler
Throws:
Throwable

getEntityName

public String getEntityName()

getData

public HashMap getData()


Copyright © 2001-2012 Red Hat, Inc. All Rights Reserved.