00001 import java.util.Hashtable; 00002 import jpl.*; 00003 00004 public class Versions 00005 { 00006 public static void 00007 main( String argv[] ) 00008 { 00009 00010 String prologVersion = ((Term) (new Query("jpl_pl_lib_version(V)")).oneSolution().get("V")).name(); 00011 String javaVersion = jpl.JPL.version_string(); 00012 String cVersion = jpl.fli.Prolog.get_c_lib_version(); 00013 00014 System.out.println( "prolog library version; " + prologVersion ); 00015 System.out.println( " java library version; " + javaVersion ); 00016 System.out.println( " c library version; " + cVersion ); 00017 00018 if ( prologVersion.equals(javaVersion) && javaVersion.equals(cVersion) ) { 00019 System.out.println( "BINGO! you appear to have the same version of each library installed"); 00020 } else { 00021 System.out.println( "WHOOPS! you appear not to have the same version of each library installed"); 00022 } 00023 00024 } 00025 00026 } 00027 00028