public static String unwrapProxyClassName ( Class < ? > type ) { String typeName = null ; if ( type != null ) { if ( type . getName ( ) . contains ( "$$EnhancerByCGLIB$$" ) ) { typeName = CGLIB_CLASSNAME_REGEXP . matcher ( type . getName ( ) ) . replaceAll ( "$1" ) ; } else if ( type . getName ( ) . contains ( "_jvst" ) ) { typeName = JAVASSIST_CLASSNAME_REGEXP . matcher ( type . getName ( ) ) . replaceAll ( "$1" ) ; } else { typeName = type . getName ( ) ; } } return typeName ; }
Unwraps the proxy type if javassist or CGLib is used