public boolean getBooleanResult() { if ( isResultSet() ) throw new ResultSetException("Not a boolean result") ; return askResult ; }
@Override public void format(OutputStream out, ResultSet resultSet) { // Use direct string output - more control JSONOutputResultSet jsonOut = new JSONOutputResultSet(out) ; ResultSetApply a = new ResultSetApply(resultSet, jsonOut) ; a.apply() ; }
public ResultSet getResultSet() { if ( ! hasBeenSet ) throw new ResultSetException("Not set") ; if ( ! isResultSet() ) throw new ResultSetException("Not a ResultSet result") ; return resultSet ; }
@Override public void format(OutputStream out, ResultSet resultSet) { XMLOutputResultSet xOut = new XMLOutputResultSet(out) ; xOut.setStylesheetURL(stylesheetURL) ; xOut.setXmlInst(includeXMLinst) ; ResultSetApply a = new ResultSetApply(resultSet, xOut) ; a.apply() ; }
public static ResultSet fromXML(String str, Model model) { XMLInputStAX x = new XMLInputStAX(str, model) ; if ( !x.isResultSet() ) throw new ResultSetException("Not a result set") ; return x.getResultSet() ; }
public static ResultSet fromJSON(InputStream input) { SPARQLResult r = new JSONInput().process(input, null) ; return r.getResultSet() ; }
public static boolean booleanFromXML(InputStream in) { { JSONInput jin = new JSONInput(in, null) ; if(!jin.isResultSet() ) return jin.getBooleanResult() ; throw new ResultSetException("Not a boolean result") ; } }
public static ResultSet fromJSON(InputStream in, Model model) { JSONInput jin = new JSONInput(in, model) ; if(jin.isResultSet() ) return jin.getResultSet() ; throw new ResultSetException("Not a result set") ; }
public static boolean booleanFromJSON(InputStream input) { SPARQLResult r = new JSONInput().process(input, null) ; return r.getBooleanResult() ; }
public static ResultSet fromXML(String str, Model model) { return make(str, model).getResultSet() ; }
static JsonObject resultSet(ResultSet resultSet) { JSONObjectResult xOut = new JSONObjectResult() ; ResultSetApply a = new ResultSetApply(resultSet, xOut) ; a.apply() ; return xOut.json ; }
public Model getModel() { if ( ! hasBeenSet ) throw new ResultSetException("Not set") ; if ( ! isModel() ) throw new ResultSetException("Not a graph result") ; return model ; }
public static boolean booleanFromXML(String str) { return make(str, null).getBooleanResult() ; }
public boolean hasNext() { if (!isResultSet) throw new ResultSetException("Not an XML result set"); if (finished) return false; if (binding == null) { binding = getOneSolution(); row++; } return binding != null; }
public void format(OutputStream out, ResultSet resultSet) { XMLOutputResultSet xOut = new XMLOutputResultSet(out) ; xOut.setStylesheetURL(stylesheetURL) ; xOut.setXmlInst(includeXMLinst) ; ResultSetApply a = new ResultSetApply(resultSet, xOut) ; a.apply() ; }
public static ResultSet fromXML(InputStream in, Model model) { XMLInputStAX x = new XMLInputStAX(in, model) ; if ( !x.isResultSet() ) throw new ResultSetException("Not a result set") ; return x.getResultSet() ; }
public void format(OutputStream out, ResultSet resultSet) { // Use direct string output - more control JSONOutputResultSet jsonOut = new JSONOutputResultSet(out) ; ResultSetApply a = new ResultSetApply(resultSet, jsonOut) ; a.apply() ; }
public ResultSet getResultSet() { if ( ! hasBeenSet ) throw new ResultSetException("Not set") ; if ( ! isResultSet() ) throw new ResultSetException("Not an ResultSet result") ; return resultSet ; }
public Model getModel() { if ( ! hasBeenSet ) throw new ResultSetException("Not set") ; if ( ! isModel() ) throw new ResultSetException("Not a graph result") ; return model ; }
public static ResultSet fromXML(String str, Model model) { XMLInputStAX x = new XMLInputStAX(str, model) ; if ( !x.isResultSet() ) throw new ResultSetException("Not a result set") ; return x.getResultSet() ; }