|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.fuin.srcgen4javassist.SgBehavior
public abstract class SgBehavior
Base class for constructors and methods.
| Constructor Summary | |
|---|---|
SgBehavior(SgClass owner,
java.lang.String modifiers)
Constructor with class and modifiers. |
|
| Method Summary | |
|---|---|
void |
addAnnotation(SgAnnotation annotation)
Adds an annotation. |
void |
addAnnotations(java.util.List<SgAnnotation> annotations)
Adds a list of annotations. |
void |
addArgument(SgArgument arg)
Adds an argument to the list. |
void |
addException(SgClass clasz)
Adds an exception to the list. |
java.util.List<SgAnnotation> |
getAnnotations()
Returns the annotations for this method. |
java.util.List<SgArgument> |
getArguments()
Returns the constructor/method arguments. |
java.util.List<SgArgument> |
getArguments(int less)
Returns the arguments from 0.. |
java.lang.String |
getCommaSeparatedArgumentNames()
Returns the argument names separated by a comma. |
java.lang.String |
getCommaSeparatedArgumentNames(int less)
Returns the argument names from 0.. |
java.util.List<SgClass> |
getExceptions()
Returns the list of exceptions thrown by the constructor/method. |
SgArgument |
getLastArgument()
Returns the last argument of the list. |
java.lang.String |
getModifiers()
Returns the modifiers for the constructor/method. |
SgClass |
getOwner()
Returns the class the behavior belongs to. |
boolean |
hasAnnotation(java.lang.String name)
Checks if a given annotation is in the list. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public SgBehavior(SgClass owner,
java.lang.String modifiers)
owner - Class the behavior belongs to - Cannot be null.modifiers - Modifiers for the constructor/method - Cannot be null (but
empty).| Method Detail |
|---|
public final SgClass getOwner()
public final java.lang.String getModifiers()
public final java.util.List<SgArgument> getArguments()
public final java.lang.String getCommaSeparatedArgumentNames(int less)
less - The number of arguments NOT to return from the end of the
list. It's always a NEGATIVE value.
public final java.lang.String getCommaSeparatedArgumentNames()
public final java.util.List<SgArgument> getArguments(int less)
less - The number of arguments NOT to return from the end of the
list. It's always a NEGATIVE value.
public final SgArgument getLastArgument()
public final void addArgument(SgArgument arg)
arg - Argument to add - Non null.public final java.util.List<SgClass> getExceptions()
public final void addException(SgClass clasz)
clasz - Exception to add.public final java.util.List<SgAnnotation> getAnnotations()
public final void addAnnotation(SgAnnotation annotation)
annotation - Annotation to add - Cannot be null.public final void addAnnotations(java.util.List<SgAnnotation> annotations)
addAll(..).
annotations - Annotations to add - Cannot be null.public final boolean hasAnnotation(java.lang.String name)
name - Name of the annotation to find - Cannot be null.
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||