org.broadleafcommerce.common.extensibility.jpa.copy
Class AnnotationsCopyClassTransformer

java.lang.Object
  extended by org.broadleafcommerce.common.extensibility.jpa.copy.AnnotationsCopyClassTransformer
All Implemented Interfaces:
javax.persistence.spi.ClassTransformer, BroadleafClassTransformer

Deprecated. do not use this class, use DirectCopyClassTransformer instead

@Deprecated
public class AnnotationsCopyClassTransformer
extends Object
implements BroadleafClassTransformer

This class transformer will copy fields, methods, and interface definitions from a source class to a target class, based on the xformTemplates map. It will fail if it encouters any duplicate definitions.

Author:
Andre Azzolini (apazzolini)

Field Summary
protected  SupportLogger logger
          Deprecated.  
protected  String moduleName
          Deprecated.  
protected static List<String> transformedMethods
          Deprecated.  
protected  Map<String,String> xformTemplates
          Deprecated.  
 
Constructor Summary
AnnotationsCopyClassTransformer(String moduleName)
          Deprecated.  
 
Method Summary
 void compileJPAProperties(Properties props, Object key)
          Deprecated.  
protected  String getImplementationType(String className)
          Deprecated. This method will do its best to return an implementation type for a given classname.
 Map<String,String> getXformTemplates()
          Deprecated.  
protected  String methodDescription(javassist.CtMethod method)
          Deprecated.  
 void setXformTemplates(Map<String,String> xformTemplates)
          Deprecated.  
 byte[] transform(ClassLoader loader, String className, Class<?> classBeingRedefined, ProtectionDomain protectionDomain, byte[] classfileBuffer)
          Deprecated.  
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

logger

protected SupportLogger logger
Deprecated. 

moduleName

protected String moduleName
Deprecated. 

xformTemplates

protected Map<String,String> xformTemplates
Deprecated. 

transformedMethods

protected static List<String> transformedMethods
Deprecated. 
Constructor Detail

AnnotationsCopyClassTransformer

public AnnotationsCopyClassTransformer(String moduleName)
Deprecated. 
Method Detail

compileJPAProperties

public void compileJPAProperties(Properties props,
                                 Object key)
                          throws Exception
Deprecated. 
Specified by:
compileJPAProperties in interface BroadleafClassTransformer
Throws:
Exception

transform

public byte[] transform(ClassLoader loader,
                        String className,
                        Class<?> classBeingRedefined,
                        ProtectionDomain protectionDomain,
                        byte[] classfileBuffer)
                 throws IllegalClassFormatException
Deprecated. 
Specified by:
transform in interface javax.persistence.spi.ClassTransformer
Throws:
IllegalClassFormatException

getImplementationType

protected String getImplementationType(String className)
Deprecated. 
This method will do its best to return an implementation type for a given classname. This will allow weaving template classes to have initialized values. We provide default implementations for List, Map, and Set, and will attempt to utilize a default constructor for other classes. If the className contains an '[', we will return null.


methodDescription

protected String methodDescription(javassist.CtMethod method)
Deprecated. 

getXformTemplates

public Map<String,String> getXformTemplates()
Deprecated. 

setXformTemplates

public void setXformTemplates(Map<String,String> xformTemplates)
Deprecated. 


Copyright © 2013. All Rights Reserved.