package org.elena.sqi; import be.cenorm.www.SqiTargetPort; import be.cenorm.www._SqiFault; import be.cenorm.www.FaultCodeType; import java.rmi.RemoteException; import edu.universal.tools.VsqiToLucene; /** * User: Sandra Aguirre * Date: 15-nov-2005 * Time: 14:30:20 */ public class Target implements SqiTargetPort { public void setQueryLanguage(String string, String string1) throws RemoteException, _SqiFault { //To change body of implemented methods use File | Settings | File Templates. } public void setMaxQueryResults(String string, int i) throws RemoteException, _SqiFault { //To change body of implemented methods use File | Settings | File Templates. } public void setMaxDuration(String string, int i) throws RemoteException, _SqiFault { //To change bo dy of implemented methods use File | Settings | File Templates. } public void setResultsFormat(String string, String string1) throws RemoteException, _SqiFault { //To change body of implemented methods use File | Settings | File Templates. } public void setResultsSetSize(String string, int i) throws RemoteException, _SqiFault { //To change body of implemented methods use File | Settings | File Templates. } public String synchronousQuery(String targetSessionID, String query, int i) throws RemoteException, _SqiFault { String results; try { results = parseQueryVsqi(query); } catch (Exception e) { throw new _SqiFault(FaultCodeType.SQI_00001, "Fault"); } return results; } public String parseQueryVsqi(String queryString) throws _SqiFault { if (queryString == null) throw new _SqiFault(FaultCodeType.SQI_00004, "The statement " + queryString + " is not valid."); String termToLucene = ""; try { termToLucene = VsqiToLucene.parserQueryVsqi(queryString); } catch (Exception e) { e.printStackTrace(); } return termToLucene; } public int getTotalResultsCount(String string, String string1) throws RemoteException, _SqiFault { return 0; //To change body of implemented methods use File | Settings | File Templates. } public void setSourceLocation(String string, String string1) throws RemoteException, _SqiFault { //To change body of implemented methods use File | Settings | File Templates. } public void asynchronousQuery(String string, String string1, String string2) throws RemoteException, _SqiFault { //To change body of implemented methods use File | Settings | File Templates. } }