I am working with JADE framework and I want to know is there any way for intelligent agents to work with some kind of data base, where they can read from it and write some information?..
I tried to make a connection between excel (using jxl) and my project but there is a problem: below is the code for writing in excel file:
public static void write(String[] args) throws Exception {
// TODO code application logic here
File f = new File("C:\\Users\\Mastisa\\Desktop\\Master.xls");
WritableWorkbook Master = Workbook.createWorkbook(f);
WritableSheet History_Table = Master.createSheet("History_Table", 0);
Label L00 = new Label (0,0,"RUN#");
History_Table.addCell(L00);
Master.write();
System.out.println("finished...");
Master.close();
}
}
but I want agents to do something like this:
Database D;
D.add(myAgent.getLocalName);
but it is not possible as jxl doesn't provide functions for working with agents. and it looks like that everything must be written in that excel file manually.... but it is not what I want.. I want agents comfortably read and write...
Is there any other way?