|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object net.mtu.eggplant.dbc.CodeFragment
Class that represents a fragment of code that needs to be inserted into a file to instrument it for assertions.
Constructor Summary | |
CodeFragment(CodePoint location,
String code,
CodeFragmentType type)
create a new CodeFragment |
Method Summary | |
int |
compareTo(Object o)
Only compares to other CodeFragments. |
boolean |
equals(Object o)
|
String |
getCode()
what code to insert |
CodePoint |
getLocation()
where to insert the code |
CodeFragmentType |
getType()
what type of assertion is this. |
int |
hashCode()
|
int |
instrumentLine(int offset,
StringBuffer line)
Instrument the given line. |
String |
toString()
|
Methods inherited from class java.lang.Object |
clone, finalize, getClass, notify, notifyAll, wait, wait, wait |
Constructor Detail |
public CodeFragment(CodePoint location, String code, CodeFragmentType type)
Method Detail |
public final CodePoint getLocation()
public final String getCode()
public final CodeFragmentType getType()
public boolean equals(Object o)
public int hashCode()
public String toString()
public int instrumentLine(int offset, StringBuffer line)
offset
- how many characters have been added to this line since it was pulled from the fileline
- the line to modify
public int compareTo(Object o) throws ClassCastException
compareTo
in interface Comparable
o
- the object to compare to
ClassCastException
- if o is not a CodeFragment
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |