Java Code Examples for jdk.internal.org.objectweb.asm.Opcodes#INVOKESPECIAL
The following examples show how to use
jdk.internal.org.objectweb.asm.Opcodes#INVOKESPECIAL .
You can vote up the ones you like or vote down the ones you don't like,
and go to the original project or source file by following the links above each example. You may check out the related API usage on the sidebar.
Example 1
Source File: InstructionAdapter.java From dragonwell8_jdk with GNU General Public License v2.0 | 6 votes |
private void doVisitMethodInsn(int opcode, final String owner, final String name, final String desc, final boolean itf) { switch (opcode) { case Opcodes.INVOKESPECIAL: invokespecial(owner, name, desc, itf); break; case Opcodes.INVOKEVIRTUAL: invokevirtual(owner, name, desc, itf); break; case Opcodes.INVOKESTATIC: invokestatic(owner, name, desc, itf); break; case Opcodes.INVOKEINTERFACE: invokeinterface(owner, name, desc); break; default: throw new IllegalArgumentException(); } }
Example 2
Source File: InstructionAdapter.java From jdk8u-jdk with GNU General Public License v2.0 | 6 votes |
private void doVisitMethodInsn(int opcode, final String owner, final String name, final String desc, final boolean itf) { switch (opcode) { case Opcodes.INVOKESPECIAL: invokespecial(owner, name, desc, itf); break; case Opcodes.INVOKEVIRTUAL: invokevirtual(owner, name, desc, itf); break; case Opcodes.INVOKESTATIC: invokestatic(owner, name, desc, itf); break; case Opcodes.INVOKEINTERFACE: invokeinterface(owner, name, desc); break; default: throw new IllegalArgumentException(); } }
Example 3
Source File: InstructionAdapter.java From openjdk-8-source with GNU General Public License v2.0 | 6 votes |
private void doVisitMethodInsn(int opcode, final String owner, final String name, final String desc, final boolean itf) { switch (opcode) { case Opcodes.INVOKESPECIAL: invokespecial(owner, name, desc, itf); break; case Opcodes.INVOKEVIRTUAL: invokevirtual(owner, name, desc, itf); break; case Opcodes.INVOKESTATIC: invokestatic(owner, name, desc, itf); break; case Opcodes.INVOKEINTERFACE: invokeinterface(owner, name, desc); break; default: throw new IllegalArgumentException(); } }
Example 4
Source File: InstructionAdapter.java From TencentKona-8 with GNU General Public License v2.0 | 6 votes |
private void doVisitMethodInsn(int opcode, final String owner, final String name, final String desc, final boolean itf) { switch (opcode) { case Opcodes.INVOKESPECIAL: invokespecial(owner, name, desc, itf); break; case Opcodes.INVOKEVIRTUAL: invokevirtual(owner, name, desc, itf); break; case Opcodes.INVOKESTATIC: invokestatic(owner, name, desc, itf); break; case Opcodes.INVOKEINTERFACE: invokeinterface(owner, name, desc); break; default: throw new IllegalArgumentException(); } }
Example 5
Source File: InstructionAdapter.java From Bytecoder with Apache License 2.0 | 6 votes |
private void doVisitMethodInsn( final int opcode, final String owner, final String name, final String descriptor, final boolean isInterface) { switch (opcode) { case Opcodes.INVOKESPECIAL: invokespecial(owner, name, descriptor, isInterface); break; case Opcodes.INVOKEVIRTUAL: invokevirtual(owner, name, descriptor, isInterface); break; case Opcodes.INVOKESTATIC: invokestatic(owner, name, descriptor, isInterface); break; case Opcodes.INVOKEINTERFACE: invokeinterface(owner, name, descriptor); break; default: throw new IllegalArgumentException(); } }
Example 6
Source File: InstructionAdapter.java From nashorn with GNU General Public License v2.0 | 6 votes |
@Override public void visitMethodInsn( final int opcode, final String owner, final String name, final String desc) { switch (opcode) { case Opcodes.INVOKESPECIAL: invokespecial(owner, name, desc); break; case Opcodes.INVOKEVIRTUAL: invokevirtual(owner, name, desc); break; case Opcodes.INVOKESTATIC: invokestatic(owner, name, desc); break; case Opcodes.INVOKEINTERFACE: invokeinterface(owner, name, desc); break; default: throw new IllegalArgumentException(); } }
Example 7
Source File: InstructionAdapter.java From jdk8u-dev-jdk with GNU General Public License v2.0 | 6 votes |
private void doVisitMethodInsn(int opcode, final String owner, final String name, final String desc, final boolean itf) { switch (opcode) { case Opcodes.INVOKESPECIAL: invokespecial(owner, name, desc, itf); break; case Opcodes.INVOKEVIRTUAL: invokevirtual(owner, name, desc, itf); break; case Opcodes.INVOKESTATIC: invokestatic(owner, name, desc, itf); break; case Opcodes.INVOKEINTERFACE: invokeinterface(owner, name, desc); break; default: throw new IllegalArgumentException(); } }
Example 8
Source File: CheckMethodAdapter.java From hottub with GNU General Public License v2.0 | 5 votes |
private void doVisitMethodInsn(int opcode, final String owner, final String name, final String desc, final boolean itf) { checkStartCode(); checkEndCode(); checkOpcode(opcode, 5); if (opcode != Opcodes.INVOKESPECIAL || !"<init>".equals(name)) { checkMethodIdentifier(version, name, "name"); } checkInternalName(owner, "owner"); checkMethodDesc(desc); if (opcode == Opcodes.INVOKEVIRTUAL && itf) { throw new IllegalArgumentException( "INVOKEVIRTUAL can't be used with interfaces"); } if (opcode == Opcodes.INVOKEINTERFACE && !itf) { throw new IllegalArgumentException( "INVOKEINTERFACE can't be used with classes"); } // Calling super.visitMethodInsn requires to call the correct version // depending on this.api (otherwise infinite loops can occur). To // simplify and to make it easier to automatically remove the backward // compatibility code, we inline the code of the overridden method here. if (mv != null) { mv.visitMethodInsn(opcode, owner, name, desc, itf); } ++insnCount; }
Example 9
Source File: CheckMethodAdapter.java From openjdk-8 with GNU General Public License v2.0 | 5 votes |
private void doVisitMethodInsn(int opcode, final String owner, final String name, final String desc, final boolean itf) { checkStartCode(); checkEndCode(); checkOpcode(opcode, 5); if (opcode != Opcodes.INVOKESPECIAL || !"<init>".equals(name)) { checkMethodIdentifier(version, name, "name"); } checkInternalName(owner, "owner"); checkMethodDesc(desc); if (opcode == Opcodes.INVOKEVIRTUAL && itf) { throw new IllegalArgumentException( "INVOKEVIRTUAL can't be used with interfaces"); } if (opcode == Opcodes.INVOKEINTERFACE && !itf) { throw new IllegalArgumentException( "INVOKEINTERFACE can't be used with classes"); } // Calling super.visitMethodInsn requires to call the correct version // depending on this.api (otherwise infinite loops can occur). To // simplify and to make it easier to automatically remove the backward // compatibility code, we inline the code of the overridden method here. if (mv != null) { mv.visitMethodInsn(opcode, owner, name, desc, itf); } ++insnCount; }
Example 10
Source File: AnalyzerAdapter.java From openjdk-8-source with GNU General Public License v2.0 | 5 votes |
private void doVisitMethodInsn(int opcode, final String owner, final String name, final String desc, final boolean itf) { if (mv != null) { mv.visitMethodInsn(opcode, owner, name, desc, itf); } if (this.locals == null) { labels = null; return; } pop(desc); if (opcode != Opcodes.INVOKESTATIC) { Object t = pop(); if (opcode == Opcodes.INVOKESPECIAL && name.charAt(0) == '<') { Object u; if (t == Opcodes.UNINITIALIZED_THIS) { u = this.owner; } else { u = uninitializedTypes.get(t); } for (int i = 0; i < locals.size(); ++i) { if (locals.get(i) == t) { locals.set(i, u); } } for (int i = 0; i < stack.size(); ++i) { if (stack.get(i) == t) { stack.set(i, u); } } } } pushDesc(desc); labels = null; }
Example 11
Source File: AnalyzerAdapter.java From openjdk-8 with GNU General Public License v2.0 | 5 votes |
private void doVisitMethodInsn(int opcode, final String owner, final String name, final String desc, final boolean itf) { if (mv != null) { mv.visitMethodInsn(opcode, owner, name, desc, itf); } if (this.locals == null) { labels = null; return; } pop(desc); if (opcode != Opcodes.INVOKESTATIC) { Object t = pop(); if (opcode == Opcodes.INVOKESPECIAL && name.charAt(0) == '<') { Object u; if (t == Opcodes.UNINITIALIZED_THIS) { u = this.owner; } else { u = uninitializedTypes.get(t); } for (int i = 0; i < locals.size(); ++i) { if (locals.get(i) == t) { locals.set(i, u); } } for (int i = 0; i < stack.size(); ++i) { if (stack.get(i) == t) { stack.set(i, u); } } } } pushDesc(desc); labels = null; }
Example 12
Source File: AnalyzerAdapter.java From openjdk-jdk8u-backup with GNU General Public License v2.0 | 5 votes |
private void doVisitMethodInsn(int opcode, final String owner, final String name, final String desc, final boolean itf) { if (mv != null) { mv.visitMethodInsn(opcode, owner, name, desc, itf); } if (this.locals == null) { labels = null; return; } pop(desc); if (opcode != Opcodes.INVOKESTATIC) { Object t = pop(); if (opcode == Opcodes.INVOKESPECIAL && name.charAt(0) == '<') { Object u; if (t == Opcodes.UNINITIALIZED_THIS) { u = this.owner; } else { u = uninitializedTypes.get(t); } for (int i = 0; i < locals.size(); ++i) { if (locals.get(i) == t) { locals.set(i, u); } } for (int i = 0; i < stack.size(); ++i) { if (stack.get(i) == t) { stack.set(i, u); } } } } pushDesc(desc); labels = null; }
Example 13
Source File: CheckMethodAdapter.java From openjdk-jdk8u with GNU General Public License v2.0 | 5 votes |
private void doVisitMethodInsn(int opcode, final String owner, final String name, final String desc, final boolean itf) { checkStartCode(); checkEndCode(); checkOpcode(opcode, 5); if (opcode != Opcodes.INVOKESPECIAL || !"<init>".equals(name)) { checkMethodIdentifier(version, name, "name"); } checkInternalName(owner, "owner"); checkMethodDesc(desc); if (opcode == Opcodes.INVOKEVIRTUAL && itf) { throw new IllegalArgumentException( "INVOKEVIRTUAL can't be used with interfaces"); } if (opcode == Opcodes.INVOKEINTERFACE && !itf) { throw new IllegalArgumentException( "INVOKEINTERFACE can't be used with classes"); } // Calling super.visitMethodInsn requires to call the correct version // depending on this.api (otherwise infinite loops can occur). To // simplify and to make it easier to automatically remove the backward // compatibility code, we inline the code of the overridden method here. if (mv != null) { mv.visitMethodInsn(opcode, owner, name, desc, itf); } ++insnCount; }
Example 14
Source File: AnalyzerAdapter.java From jdk8u-dev-jdk with GNU General Public License v2.0 | 5 votes |
private void doVisitMethodInsn(int opcode, final String owner, final String name, final String desc, final boolean itf) { if (mv != null) { mv.visitMethodInsn(opcode, owner, name, desc, itf); } if (this.locals == null) { labels = null; return; } pop(desc); if (opcode != Opcodes.INVOKESTATIC) { Object t = pop(); if (opcode == Opcodes.INVOKESPECIAL && name.charAt(0) == '<') { Object u; if (t == Opcodes.UNINITIALIZED_THIS) { u = this.owner; } else { u = uninitializedTypes.get(t); } for (int i = 0; i < locals.size(); ++i) { if (locals.get(i) == t) { locals.set(i, u); } } for (int i = 0; i < stack.size(); ++i) { if (stack.get(i) == t) { stack.set(i, u); } } } } pushDesc(desc); labels = null; }
Example 15
Source File: AnalyzerAdapter.java From nashorn with GNU General Public License v2.0 | 5 votes |
@Override public void visitMethodInsn( final int opcode, final String owner, final String name, final String desc) { if (mv != null) { mv.visitMethodInsn(opcode, owner, name, desc); } if (this.locals == null) { labels = null; return; } pop(desc); if (opcode != Opcodes.INVOKESTATIC) { Object t = pop(); if (opcode == Opcodes.INVOKESPECIAL && name.charAt(0) == '<') { Object u; if (t == Opcodes.UNINITIALIZED_THIS) { u = this.owner; } else { u = uninitializedTypes.get(t); } for (int i = 0; i < locals.size(); ++i) { if (locals.get(i) == t) { locals.set(i, u); } } for (int i = 0; i < stack.size(); ++i) { if (stack.get(i) == t) { stack.set(i, u); } } } } pushDesc(desc); labels = null; }
Example 16
Source File: CheckMethodAdapter.java From jdk8u60 with GNU General Public License v2.0 | 5 votes |
private void doVisitMethodInsn(int opcode, final String owner, final String name, final String desc, final boolean itf) { checkStartCode(); checkEndCode(); checkOpcode(opcode, 5); if (opcode != Opcodes.INVOKESPECIAL || !"<init>".equals(name)) { checkMethodIdentifier(version, name, "name"); } checkInternalName(owner, "owner"); checkMethodDesc(desc); if (opcode == Opcodes.INVOKEVIRTUAL && itf) { throw new IllegalArgumentException( "INVOKEVIRTUAL can't be used with interfaces"); } if (opcode == Opcodes.INVOKEINTERFACE && !itf) { throw new IllegalArgumentException( "INVOKEINTERFACE can't be used with classes"); } // Calling super.visitMethodInsn requires to call the correct version // depending on this.api (otherwise infinite loops can occur). To // simplify and to make it easier to automatically remove the backward // compatibility code, we inline the code of the overridden method here. if (mv != null) { mv.visitMethodInsn(opcode, owner, name, desc, itf); } ++insnCount; }
Example 17
Source File: AnalyzerAdapter.java From jdk8u60 with GNU General Public License v2.0 | 5 votes |
private void doVisitMethodInsn(int opcode, final String owner, final String name, final String desc, final boolean itf) { if (mv != null) { mv.visitMethodInsn(opcode, owner, name, desc, itf); } if (this.locals == null) { labels = null; return; } pop(desc); if (opcode != Opcodes.INVOKESTATIC) { Object t = pop(); if (opcode == Opcodes.INVOKESPECIAL && name.charAt(0) == '<') { Object u; if (t == Opcodes.UNINITIALIZED_THIS) { u = this.owner; } else { u = uninitializedTypes.get(t); } for (int i = 0; i < locals.size(); ++i) { if (locals.get(i) == t) { locals.set(i, u); } } for (int i = 0; i < stack.size(); ++i) { if (stack.get(i) == t) { stack.set(i, u); } } } } pushDesc(desc); labels = null; }
Example 18
Source File: AnalyzerAdapter.java From openjdk-jdk9 with GNU General Public License v2.0 | 5 votes |
private void doVisitMethodInsn(int opcode, final String owner, final String name, final String desc, final boolean itf) { if (mv != null) { mv.visitMethodInsn(opcode, owner, name, desc, itf); } if (this.locals == null) { labels = null; return; } pop(desc); if (opcode != Opcodes.INVOKESTATIC) { Object t = pop(); if (opcode == Opcodes.INVOKESPECIAL && name.charAt(0) == '<') { Object u; if (t == Opcodes.UNINITIALIZED_THIS) { u = this.owner; } else { u = uninitializedTypes.get(t); } for (int i = 0; i < locals.size(); ++i) { if (locals.get(i) == t) { locals.set(i, u); } } for (int i = 0; i < stack.size(); ++i) { if (stack.get(i) == t) { stack.set(i, u); } } } } pushDesc(desc); labels = null; }
Example 19
Source File: AnalyzerAdapter.java From TencentKona-8 with GNU General Public License v2.0 | 5 votes |
private void doVisitMethodInsn(int opcode, final String owner, final String name, final String desc, final boolean itf) { if (mv != null) { mv.visitMethodInsn(opcode, owner, name, desc, itf); } if (this.locals == null) { labels = null; return; } pop(desc); if (opcode != Opcodes.INVOKESTATIC) { Object t = pop(); if (opcode == Opcodes.INVOKESPECIAL && name.charAt(0) == '<') { Object u; if (t == Opcodes.UNINITIALIZED_THIS) { u = this.owner; } else { u = uninitializedTypes.get(t); } for (int i = 0; i < locals.size(); ++i) { if (locals.get(i) == t) { locals.set(i, u); } } for (int i = 0; i < stack.size(); ++i) { if (stack.get(i) == t) { stack.set(i, u); } } } } pushDesc(desc); labels = null; }
Example 20
Source File: CheckMethodAdapter.java From dragonwell8_jdk with GNU General Public License v2.0 | 5 votes |
private void doVisitMethodInsn(int opcode, final String owner, final String name, final String desc, final boolean itf) { checkStartCode(); checkEndCode(); checkOpcode(opcode, 5); if (opcode != Opcodes.INVOKESPECIAL || !"<init>".equals(name)) { checkMethodIdentifier(version, name, "name"); } checkInternalName(owner, "owner"); checkMethodDesc(desc); if (opcode == Opcodes.INVOKEVIRTUAL && itf) { throw new IllegalArgumentException( "INVOKEVIRTUAL can't be used with interfaces"); } if (opcode == Opcodes.INVOKEINTERFACE && !itf) { throw new IllegalArgumentException( "INVOKEINTERFACE can't be used with classes"); } // Calling super.visitMethodInsn requires to call the correct version // depending on this.api (otherwise infinite loops can occur). To // simplify and to make it easier to automatically remove the backward // compatibility code, we inline the code of the overridden method here. if (mv != null) { mv.visitMethodInsn(opcode, owner, name, desc, itf); } ++insnCount; }