jasm.lang
Class ClassFile.Method

java.lang.Object
  extended by jasm.lang.ClassFile.Method
Enclosing class:
ClassFile

public static class ClassFile.Method
extends java.lang.Object


Field Summary
protected  java.util.ArrayList<BytecodeAttribute> attributes
           
protected  java.util.List<Modifier> modifiers
           
protected  java.lang.String name
           
protected  JvmType.Function type
           
 
Constructor Summary
ClassFile.Method(java.lang.String name, JvmType.Function type, java.util.List<Modifier> modifiers)
           
 
Method Summary
<T extends BytecodeAttribute>
T
attribute(java.lang.Class<T> c)
           
 BytecodeAttribute attribute(java.lang.String name)
           
 java.util.List<BytecodeAttribute> attributes()
           
 java.util.List<JvmType.Clazz> exceptions()
           
 boolean hasModifier(java.lang.Class modClass)
          Check whether this method has one of the "base" modifiers (e.g.
 boolean isAbstract()
          Check whether this method is abstract
 boolean isFinal()
          Check whether this method is final
 boolean isNative()
          Check whether this method is native
 boolean isPrivate()
          Check whether this method is private
 boolean isProtected()
          Check whether this method is protected
 boolean isPublic()
          Check whether this method is public
 boolean isStatic()
          Check whether this method is static
 boolean isSynchronized()
          Check whether this method is synchronized
 boolean isSynthetic()
          Check whether this method is synthetic
 boolean isVariableArity()
          Check whether this method has varargs
 java.util.List<Modifier> modifiers()
           
 java.lang.String name()
           
 java.util.List<ClassFile.Parameter> parameters()
           
 void setType(JvmType.Function t)
           
 JvmType.Function type()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

name

protected java.lang.String name

type

protected JvmType.Function type

modifiers

protected java.util.List<Modifier> modifiers

attributes

protected java.util.ArrayList<BytecodeAttribute> attributes
Constructor Detail

ClassFile.Method

public ClassFile.Method(java.lang.String name,
                        JvmType.Function type,
                        java.util.List<Modifier> modifiers)
Method Detail

name

public java.lang.String name()

type

public JvmType.Function type()

setType

public void setType(JvmType.Function t)

parameters

public java.util.List<ClassFile.Parameter> parameters()

modifiers

public java.util.List<Modifier> modifiers()

exceptions

public java.util.List<JvmType.Clazz> exceptions()

attribute

public <T extends BytecodeAttribute> T attribute(java.lang.Class<T> c)

attributes

public java.util.List<BytecodeAttribute> attributes()

attribute

public BytecodeAttribute attribute(java.lang.String name)

hasModifier

public boolean hasModifier(java.lang.Class modClass)
Check whether this method has one of the "base" modifiers (e.g. static, public, private, etc). These are found in Modifier.ACC_

Parameters:
modifier -
Returns:
true if it does!

isAbstract

public boolean isAbstract()
Check whether this method is abstract


isFinal

public boolean isFinal()
Check whether this method is final


isStatic

public boolean isStatic()
Check whether this method is static


isPublic

public boolean isPublic()
Check whether this method is public


isProtected

public boolean isProtected()
Check whether this method is protected


isPrivate

public boolean isPrivate()
Check whether this method is private


isNative

public boolean isNative()
Check whether this method is native


isSynchronized

public boolean isSynchronized()
Check whether this method is synchronized


isSynthetic

public boolean isSynthetic()
Check whether this method is synthetic


isVariableArity

public boolean isVariableArity()
Check whether this method has varargs



Copyright © 2013 David J. Pearce. All Rights Reserved.