AW: AW: Storing ThingDescription in Dataset

2021-07-31 Thread Philipp Leeb
Nvm, fixed dependency problem and this fixes my problem. -Ursprüngliche Nachricht- Von: Andy Seaborne Gesendet: Samstag, 31. Juli 2021 11:54 An: users@jena.apache.org Betreff: Re: AW: Storing ThingDescription in Dataset > But i get: > Exception in thread

AW: AW: Storing ThingDescription in Dataset

2021-07-31 Thread Philipp Leeb
] \- org.glassfish:jakarta.json:jar:2.0.0:compile There is just one import of commons-codec with version 1.11 -Ursprüngliche Nachricht- Von: Andy Seaborne Gesendet: Samstag, 31. Juli 2021 11:54 An: users@jena.apache.org Betreff: Re: AW: Storing ThingDescription in Dataset > But i get: > Exc

Re: AW: Storing ThingDescription in Dataset

2021-07-31 Thread Andy Seaborne
But i get: Exception in thread "main" org.apache.jena.ext.com.google.common.util.concurrent.ExecutionError: java.lang.NoClassDefFoundError: org/apache/commons/codec/digest/MurmurHash3 No commons-codec on the classpath, or there is an old version being picked up by dependency resolution

AW: Storing ThingDescription in Dataset

2021-07-31 Thread Philipp Leeb
pache.jena.riot.RDFParser.parse(RDFParser.java:295) at org.apache.jena.riot.RDFParserBuilder.parse(RDFParserBuilder.java:550) at org.apache.jena.riot.RDFDataMgr.parseFromInputStream(RDFDataMgr.java:721) at org.apache.jena.riot.RDFDataMgr.read(RDFDataMgr.java:510)

Re: Storing ThingDescription in Dataset

2021-07-27 Thread Andy Seaborne
to convert titanium-Dataset to jena-Dataset. -Ursprüngliche Nachricht- Von: Andy Seaborne Gesendet: Sonntag, 25. Juli 2021 18:58 An: users@jena.apache.org Betreff: Re: AW: AW: AW: Storing ThingDescription in Dataset On 25/07/2021 12:47, Philipp Leeb wrote: Doesn't work either. What

AW: AW: AW: AW: Storing ThingDescription in Dataset

2021-07-26 Thread Philipp Leeb
Didn't see any way to convert titanium-Dataset to jena-Dataset. -Ursprüngliche Nachricht- Von: Andy Seaborne Gesendet: Sonntag, 25. Juli 2021 18:58 An: users@jena.apache.org Betreff: Re: AW: AW: AW: Storing ThingDescription in Dataset On 25/07/2021 12:47, Philipp Leeb wrote

Re: AW: AW: AW: Storing ThingDescription in Dataset

2021-07-25 Thread Andy Seaborne
-Ursprüngliche Nachricht- Von: Andy Seaborne Gesendet: Sonntag, 25. Juli 2021 13:17 An: users@jena.apache.org Betreff: Re: AW: AW: Storing ThingDescription in Dataset Jena prints an error. 2:12:36 ERROR riot:: invalid term definition: 1.1 The playgound says it's JSON-LD 1.1 which

AW: AW: AW: Storing ThingDescription in Dataset

2021-07-25 Thread Philipp Leeb
Doesn't work either. Is there any other way of how to add my TD in JSOn-LD into my dataset? -Ursprüngliche Nachricht- Von: Andy Seaborne Gesendet: Sonntag, 25. Juli 2021 13:17 An: users@jena.apache.org Betreff: Re: AW: AW: Storing ThingDescription in Dataset Jena prints an error. 2

Re: AW: AW: Storing ThingDescription in Dataset

2021-07-25 Thread Andy Seaborne
lue" : "_:b7" } }, { "subject" : { "type" : "blank node", "value" : "_:b6" }, "predicate" : { "type" : "IRI", "value" : "https://www.w3.org/2019/wo

AW: AW: Storing ThingDescription in Dataset

2021-07-25 Thread Philipp Leeb
"subject" : { "type" : "blank node", "value" : "_:b6" }, "predicate" : { "type" : "IRI", "value" : "https://www.w3.org/2019/wot/td#hasForm; }, "object" : { &quo

Re: AW: Storing ThingDescription in Dataset

2021-07-25 Thread Andy Seaborne
Hi Phil, That does not look like JSON-LD. JSON-LD parsing ignores anything it does not understand, not give an error. In your code snippet, no Jena involved, Object compact is a jsonld-data object "Dataset" (which isn't a Jena Dataset) with nothing in it. JSON-LD parsing ignores

AW: Storing ThingDescription in Dataset

2021-07-25 Thread Philipp Leeb
quot;, "value" : "_:b7" }, "predicate" : { "type" : "IRI", "value" : "htv:methodName" }, "object" : { "type" : "literal", "value"

Re: Storing ThingDescription in Dataset

2021-07-25 Thread Andy Seaborne
Hi Phil, Jena has an RDF reader that wraps up the use of jsonld-java so you don't have to use jsonld-java code directly. InputStream in = ... Dataset dataset = ... RDFDataMgr.read(dataset, in, Lang.JSONLD); If you want to see the source code to see how it uses

Storing ThingDescription in Dataset

2021-07-25 Thread Philipp Leeb
Hey guys, I'm trying to store a WoT-TD (JSON-LD format) in Dataset of embedded fuseki. When using: InputStream inputStream = new ByteArrayInputStream(exposedThing.toJson().getBytes(StandardCharsets.UTF_8)) ; Object jsonObject = JsonUtils.fromInputStream(inputStream); Object compact =