I have a prolog file (Expert System) that I consult from Java using Jpl libraries (org.jpl7.*) and I have an UI using jframe where I want to show the output of prolog's queries.when consult prolog file in netbeans,read() predicate runs in console java;i want run in jtextarea in interface.Can anyone tell me how I can do that?
In this UI I have jtextarea for answer and another jtextarea for grade. This is prolog code using swi prolog:
Question1 = "Define computer?",
Word_list1 = ["software","operatingsystem"],
Word_list2 = ["hardware","tools"],
Msg = "Write your answers ",
split_string(Low_answer," ,.()-_"," ,.()-_", Answer_in_list),
Total_grade is Grade1 + Grade2,
nl,write("Your grade is : "), write(Total_grade),nl.
This is netbeans code:
Query q1=new Query(t1);
Query c=new Query(c1);