Package com.comphenix.protocol.reflect.compiler

Examples of com.comphenix.protocol.reflect.compiler.EmptyMethodVisitor


      public MethodVisitor visitMethod(int access, String name, String desc, String signature, String[] exceptions) {
        final String methodName = name;
       
        // Detect read/write calls to NBTTagCompound
        if (expectedDesc.equals(desc)) {
          return new EmptyMethodVisitor() {
            private int readMethods;
            private int writeMethods;
           
            public void visitMethodInsn(int opcode, String owner, String name, String desc) {
              // This must be a virtual call on NBTTagCompound that accepts a String
View Full Code Here


    reader.accept(new EmptyClassVisitor() {
      @Override
      public MethodVisitor visitMethod(int access, String name, String desc, String signature, String[] exceptions) {
        // Check method
        if (methodName.equals(name) && methodDescription.equals(desc)) {
          return new EmptyMethodVisitor() {
            @Override
            public void visitMethodInsn(int opcode, String owner, String name, String desc) {
              output.add(new AsmMethod(AsmOpcodes.fromIntOpcode(opcode), owner, methodName, desc));
            }
          };
View Full Code Here

        reader.accept(new EmptyClassVisitor() {
          @Override
          public MethodVisitor visitMethod(int access, String name, String desc, String signature, String[] exceptions) {
            // The read method
            if (desc.startsWith("(Ljava/io/DataInput")) {
              return new EmptyMethodVisitor() {
                public void visitMethodInsn(int opcode, String owner, String name, String desc) {
                  if (opcode == Opcodes.INVOKESPECIAL && isConstructor(name)) {
                    String className = owner.replace('/', '.');
                   
                    // Use signature to distinguish between constructors
View Full Code Here

TOP

Related Classes of com.comphenix.protocol.reflect.compiler.EmptyMethodVisitor

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.