Main Page   Packages   Class Hierarchy   Alphabetical List   Compound List   File List   Compound Members  

JavaLangThrowableReflection.java

00001 package gov.nasa.arc.ase.jpf.jvm.reflection;
00002 
00003 import gov.nasa.arc.ase.jpf.jvm.*;
00004 import gov.nasa.arc.ase.jpf.jvm.bytecode.Instruction;
00005 
00006 public class JavaLangThrowableReflection extends Reflection {
00007   public Instruction executeMethod(MethodInfo mi) {
00008     String name = mi.getFullName();
00009 
00010     if(name.equals("fillInStackTrace()Ljava/lang/Throwable;")) {
00011       return exitReference(-1);
00012     }
00013 
00014     if(name.equals("printStackTrace0(Ljava/lang/Object;)V")) {
00015       // throws a runtime exception for now
00016       throw new NativeMethodException("printStackTrace0(Ljava/lang/Object;)V");
00017     }
00018 
00019     return super.executeMethod(mi);
00020   }  
00021   public boolean isMethodDeterministic(MethodInfo mi) {
00022     String name = mi.getFullName();
00023 
00024     if(name.equals("printStackTrace0(Ljava/lang/Object;)V")) {
00025       // throws a runtime exception for now
00026       throw new NativeMethodException("printStackTrace0(Ljava/lang/Object;)V");
00027     }
00028 
00029     return super.isMethodDeterministic(mi);
00030   }  
00031   public boolean isMethodExecutable(MethodInfo mi) {
00032     String name = mi.getFullName();
00033 
00034     if(name.equals("printStackTrace0(Ljava/lang/Object;)V")) {
00035       // throws a runtime exception for now
00036       throw new NativeMethodException("printStackTrace0(Ljava/lang/Object;)V");
00037     }
00038 
00039     return super.isMethodExecutable(mi);
00040   }  
00041 }

Generated at Thu Feb 7 06:48:20 2002 for Bandera by doxygen1.2.10 written by Dimitri van Heesch, © 1997-2001