Package javassist

Examples of javassist.CtClass.subclassOf()


        if (!cp.getFieldrefName(index).equals(fname))
            return null;

        try {
            CtClass c = pool.get(cp.getFieldrefClassName(index));
            if (is_private ? c == fclass : c.subclassOf(fclass))
                return cp.getFieldrefType(index);
        }
        catch (NotFoundException e) {}
        return null;
    }
View Full Code Here


                // This is a problem when loading PlayPlugins bundled as regular app-class since it uses the same classloader
                // as the other (soon to be) enhanched play-app-classes.
                boolean shouldEnhance = true;
                try {
                    CtClass ctClass = enhanceChecker_classPool.makeClass(new ByteArrayInputStream(this.enhancedByteCode));
                    if (ctClass.subclassOf(ctPlayPluginClass)) {
                        shouldEnhance = false;
                    }
                } catch( Exception e) {
                    // nop
                }
View Full Code Here

    Class<?> result = null;

    try {
      CtClass cc = pool.get(className);
        boolean transformed = true;
      if (cc.subclassOf(pool.get(ActiveRecord.class.getName())) && furtherCheckAllowedToChange(cc)) {
        addMethods(cc, ClassWorkSource.arMethods);
      }
      else {
        transformed = false;
      }
View Full Code Here

         try {
            classToLoad = GwtClassPool.getClass(className);
         } catch (GwtTestPatchException e) {
            // nothing to do, it must be a Jso$ class
         }
         return classToLoad != null && classToLoad.subclassOf(JSO_CTCLASS)
                  && classToLoad != JSO_CTCLASS;

      }
   }
View Full Code Here

        if (ctClass.subtypeOf(classPool.get(siena.Json.class.getName()))) {
            return;
        }
        boolean isModel = false;
       
        if(ctClass.subclassOf(classPool.get(siena.Model.class.getName()))){
          isModel = true;
        }    
        else {       
          CtField[] fields = ctClass.getDeclaredFields();
          CtClass cl = ctClass;
View Full Code Here

                // This is a problem when loading PlayPlugins bundled as regular app-class since it uses the same classloader
                // as the other (soon to be) enhanched play-app-classes.
                boolean shouldEnhance = true;
                try {
                    CtClass ctClass = enhanceChecker_classPool.makeClass(new ByteArrayInputStream(this.enhancedByteCode));
                    if (ctClass.subclassOf(ctPlayPluginClass)) {
                        shouldEnhance = false;
                    }
                } catch( Exception e) {
                    // nop
                }
View Full Code Here

                // This is a problem when loading YalpPlugins bundled as regular app-class since it uses the same classloader
                // as the other (soon to be) enhanched yalp-app-classes.
                boolean shouldEnhance = true;
                try {
                    CtClass ctClass = enhanceChecker_classPool.makeClass(new ByteArrayInputStream(this.enhancedByteCode));
                    if (ctClass.subclassOf(ctYalpPluginClass)) {
                        shouldEnhance = false;
                    }
                } catch (Exception e) {
                    // nop
                }
View Full Code Here

            try {
                if (cache == null)
                    cache = cp.get(oldName);
   
                CtClass cache2 = cp.get(typeName);
                if (cache2.subclassOf(cache)) {
                    cache = cache2;
                    return true;
                }
                else
                    return false;
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.