Re: [3.0.1] ResultSetFactory.fromJSON() won't parse ASK JSON result

2018-03-14 Thread Andy Seaborne
On 14/03/18 12:48, Martynas Jusevičius wrote: Andy, I don't think that helps much. In fact, I think treating ASK result differently from SELECT breaks some abstractions. What I mean is that the result data structure normally maps to a media type and not its query form. That way we can have

Re: [3.0.1] ResultSetFactory.fromJSON() won't parse ASK JSON result

2018-03-14 Thread Martynas Jusevičius
Andy, I don't think that helps much. In fact, I think treating ASK result differently from SELECT breaks some abstractions. What I mean is that the result data structure normally maps to a media type and not its query form. That way we can have generic parsers/serializers that are orthogonal to

Re: [3.0.1] ResultSetFactory.fromJSON() won't parse ASK JSON result

2018-03-12 Thread Andy Seaborne
JSONInput.make(InputStream) -> SPARQLResult Andy On 12/03/18 10:13, Martynas Jusevičius wrote: Hi Andy, I'm not using QueryExecution here, I'm trying to parse JSON read from HTTP InputStream using ResultSetFactory.fromJSON(). Then I want to carry the result set, maybe do some logic based

Re: [3.0.1] ResultSetFactory.fromJSON() won't parse ASK JSON result

2018-03-12 Thread Martynas Jusevičius
Hi Andy, I'm not using QueryExecution here, I'm trying to parse JSON read from HTTP InputStream using ResultSetFactory.fromJSON(). Then I want to carry the result set, maybe do some logic based on it, and possibly serialize it back using ResultSetFormatter. Is that not possible with ASK result?

Re: [3.0.1] ResultSetFactory.fromJSON() won't parse ASK JSON result

2018-03-12 Thread Andy Seaborne
On 11/03/18 23:03, Martynas Jusevičius wrote: Hi, I'm getting the following JSON result from an ASK query: { "head": {}, "boolean": true } However, the method that usually works fine, will not parse it from InputStream (Jena 3.0.1):

[3.0.1] ResultSetFactory.fromJSON() won't parse ASK JSON result

2018-03-11 Thread Martynas Jusevičius
Hi, I'm getting the following JSON result from an ASK query: { "head": {}, "boolean": true } However, the method that usually works fine, will not parse it from InputStream (Jena 3.0.1): org.apache.jena.sparql.resultset.ResultSetException: Not a ResultSet result