sane-city / wot-servient

W3C Web of Things implementation for Java
MIT License
29 stars 5 forks source link

Define own metadata #41

Closed LeebPhil closed 3 years ago

LeebPhil commented 3 years ago

Hey guys,

i wanted to ask if it is possible to define own metadata, just like you can set a title from java code:

setTitle("title")

or is this only possible when loading from json? To provide an example what i think it could/should look like: https://github.com/w3c/wot-discovery/blob/main/proposals/geolocation.md#static-location

Kind regards Phil

HeikoBornholdt commented 3 years ago

Hey,

sorry for the late response. Currently, this is not possible (neither when reading a JSON/Thing Description, nor when writing). I can add a generic method (e.g., setMetadata(String,Object) or/and addMetadata(String,Object)) through which you can add your own metadata. Would this be ok for you?

LeebPhil commented 3 years ago

Hey @heikobornholdt ,

no problem. This would be great if such a method exists!

Best reagrds
Phil

LeebPhil commented 3 years ago

@heikobornholdt

can you estimate how long it will take you until this feature is available?

HeikoBornholdt commented 3 years ago

This week Am 28. Juni 2021, 12:30 +0200 schrieb LeebPhil @.***>:

@heikobornholdt can you estimate how long it will take you until this feature is available? — You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub, or unsubscribe.

LeebPhil commented 3 years ago

@heikobornholdt

Thank you!

HeikoBornholdt commented 3 years ago

I need a few more days. Sorry for the delay. Am 30. Juni 2021, 16:17 +0200 schrieb LeebPhil @.***>:

@heikobornholdt Thank you! — You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub, or unsubscribe.

LeebPhil commented 3 years ago

@heikobornholdt

no problem.

LeebPhil commented 3 years ago

@heikobornholdt

any update on how long it will take?

HeikoBornholdt commented 3 years ago

Sorry for the delay and thank you for your patience. The last few days driving very busy.

I've merged the requested feature into the master branch. You can try it out by using version 1.16-SNAPSHOT. Do not hesitate to contact me if you have any problems.