00001 package jpl.test; 00002 00003 import jpl.Query; 00004 00005 public class Ga { 00006 public static void main(String argv[]) { 00007 // Prolog.set_default_init_args(new String[] { "libpl.dll", "-f", "D:/pcm/bin/pcm.ini", "-g", "pcm_2000" }); 00008 // (new Query("loadall(jpl_test:jr)")).hasSolution(); 00009 // System.err.println("jr " + ((new Query("jr")).hasSolution() ? "succeeded" : "failed")); 00010 // System.err.println( "something " + (new Query("statistics(atoms,X)")).oneSolution().get("X")); 00011 // Query.hasSolution("statistics"); 00012 // (new Query("x")).hasSolution(); 00013 // (new Query("statistics,x")).hasSolution(); 00014 // (new Query(new Atom("statistics"))).hasSolution(); 00015 // Query.hasSolution("write(hello),nl"); 00016 // Query.hasSolution("write(hello),nl"); 00017 00018 // (new Query("nl")).hasSolution(); 00019 (new Query("nl,nl")).hasSolution(); 00020 00021 // (new Query("user:nl")).hasSolution(); 00022 } 00023 }