Package org.deuce.objectweb.asm

Examples of org.deuce.objectweb.asm.FieldVisitor


            CheckMethodAdapter.checkFieldSignature(signature);
        }
        if (value != null) {
            CheckMethodAdapter.checkConstant(value);
        }
        FieldVisitor av = cv.visitField(access, name, desc, signature, value);
        return new CheckFieldAdapter(av);
    }
View Full Code Here


     * Makes the given class visitor visit this field.
     *
     * @param cv a class visitor.
     */
    public void accept(final ClassVisitor cv) {
        FieldVisitor fv = cv.visitField(access, name, desc, signature, value);
        if (fv == null) {
            return;
        }
        int i, n;
        n = visibleAnnotations == null ? 0 : visibleAnnotations.size();
        for (i = 0; i < n; ++i) {
            AnnotationNode an = (AnnotationNode) visibleAnnotations.get(i);
            an.accept(fv.visitAnnotation(an.desc, true));
        }
        n = invisibleAnnotations == null ? 0 : invisibleAnnotations.size();
        for (i = 0; i < n; ++i) {
            AnnotationNode an = (AnnotationNode) invisibleAnnotations.get(i);
            an.accept(fv.visitAnnotation(an.desc, false));
        }
        n = attrs == null ? 0 : attrs.size();
        for (i = 0; i < n; ++i) {
            fv.visitAttribute((Attribute) attrs.get(i));
        }
        fv.visitEnd();
    }
View Full Code Here

   */
  @Override
  public FieldVisitor visitField(int access, String name, String desc, String signature,
      Object value) {

    FieldVisitor fieldVisitor = super.visitField(access, name, desc, signature, value);
    if( exclude)
      return fieldVisitor;
   
    // Define as constant
    int fieldAccess = Opcodes.ACC_PUBLIC | Opcodes.ACC_STATIC | Opcodes.ACC_SYNTHETIC;
View Full Code Here

      cv.visitEnd();
  }

  public FieldVisitor visitField(int access, String name, String desc,
      String signature, Object value) {
    FieldVisitor t = null;
    for (ClassVisitor cv : cvs)
      cv.visitField(access, name, desc, signature, value);
    return t;
  }
View Full Code Here

   
    if(urmdtl == null){
      return;
    }
   
    FieldVisitor fv;
    MethodVisitor mv;
   
    //Add Fields
    fv = cw.visitField(ACC_PRIVATE + Opcodes.ACC_FINAL + ACC_STATIC, Names.SerialVersionUID, "J", null, new Long(1L));
    fv.visitEnd();
       
    fv = cw.visitField(0, "locator", Type.getObjectType(Names.AlephDirectoryManager).getDescriptor(), null, null);
    fv.visitEnd();
   
    //Add Constructor
    {
      mv = cw.visitMethod(ACC_PUBLIC, "<init>", "()V", null, new String[] { Names.RMIException });
      mv.visitCode();
View Full Code Here

TOP

Related Classes of org.deuce.objectweb.asm.FieldVisitor

Copyright © 2018 www.massapicom. 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.