|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object sofya.mutator.verifier.JustIceVerifier
public final class JustIceVerifier
Wrapper for BCEL's JustIce
verifier.
This verifier has significant limitations. It is incomplete, and thus will report verification failures on classes generated by the Sun compiler, a behavior that has been observed so far on pass 3a. It also does not report verification failures in a manner easily handled programmatically, though it does produce understandable messages. Finally, it cannot report the pass on which verification failed if it is a verification pass that precedes the requested pass.
Nested Class Summary |
---|
Nested classes/interfaces inherited from interface sofya.mutator.verifier.Verifier |
---|
Verifier.Pass |
Constructor Summary | |
---|---|
JustIceVerifier()
|
Method Summary | |
---|---|
void |
loadClass(org.apache.bcel.classfile.JavaClass clazz)
Loads a class, overriding any existing definition of the class. |
void |
loadClass(java.lang.String className,
byte[] classBytes)
Loads a class, overriding any existing definition of the class. |
VerificationResult |
verify(java.lang.String className,
java.lang.String methodName,
java.lang.String signature,
Verifier.Pass level)
Verifies a method. |
VerificationResult |
verify(java.lang.String className,
Verifier.Pass level)
Verifies a class. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public JustIceVerifier()
Method Detail |
---|
public void loadClass(org.apache.bcel.classfile.JavaClass clazz)
Verifier
This method is used to instruct the verifier to load the mutated bytecode of the class to be verified. The verifier should therefore ensure that no subsequent requests to verify the given class will operate on any cached version of the class.
loadClass
in interface Verifier
clazz
- BCEL representation of the class to be loaded.public void loadClass(java.lang.String className, byte[] classBytes) throws VerifierException
Verifier
This method is used to instruct the verifier to load the mutated bytecode of the class to be verified. The verifier should therefore ensure that no subsequent requests to verify the given class will operate on any cached version of the class.
loadClass
in interface Verifier
className
- Name of the class to be loaded.classBytes
- The bytes comprising the class to be loaded.
VerifierException
- If an error prevents the class from being
loaded.public VerificationResult verify(java.lang.String className, java.lang.String methodName, java.lang.String signature, Verifier.Pass level) throws VerifierException
Verifier
verify
in interface Verifier
className
- Name of the class implementing the method to be
verified.methodName
- Name of the method to be verified.signature
- Signature of the method to be verified.level
- Verification pass to be applied. Only passes 3a
and 3b will actually verify the specific method.
VerifierException
- If the verifier is unable to execute
on the method for any reason, such as if requested method cannot
be found in the given class.public VerificationResult verify(java.lang.String className, Verifier.Pass level) throws VerifierException
Verifier
verify
in interface Verifier
className
- Name of the class to be verified.level
- Verification pass to be applied. When chosen,
passes 3a and 3b will be applied to every method in the class.
VerifierException
- If the verifier is unable to execute
on the class for any reason.
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |