Closed LeebPhil closed 3 years ago
You can find all supported units in this file: https://github.com/egonw/jqudt/blob/master/src/main/resources/onto/unit
Thanks, i've now tried to get one of the units for two days, but can't get it done.
Could you please provide an example on how to get one of these units?
Kind regards
Phil
What do you mean with "get one of the units" ?
Just like in your example:
Quantity obs = new Quantity(0.1, ConcentrationUnit.MICROMOLAR);
System.out.println(obs + " = " + obs.convertTo(ConcentrationUnit.NANOMOLAR));
I don't understand how the parameter has to look like in
Unit unit = UnitFactory.getInstance().getUnit("onto/unit");
Found the solution to my problem, should have been
Unit unit = UnitFactory.getInstance().getUnit("http://qudt.org/vocab/unit#Centimeter")
because it is named #Centimeter
in https://github.com/egonw/jqudt/blob/master/src/main/resources/onto/unit while it is named CentiM here http://qudt.org/vocab/unit/CentiM
That confused me a lot.
Sorry, I have been really busy, and currently cannot keep up with all the work. I would need to check, but I'm fairly sure the version of QUDT that I have is too old, but haven't been able to pin down the changes with the newer QUDT releases :/
Hi. I'm involved in QUDT and indeed you are using a fairly old release. The latest official Release is 2.1.11.
Also, a while back we developed a grammar for unit URIs, documented here, which is why Centimeter is now CentiM.
Let me know if you have any more questions about QUDT. It's great that you have developed this Java library!
Hi. I'm involved in QUDT and indeed you are using a fairly old release. The latest official Release is 2.1.11.
Also, a while back we developed a grammar for unit URIs, documented here, which is why Centimeter is now CentiM.
Let me know if you have any more questions about QUDT. It's great that you have developed this Java library!
Correct me please if i got wrong, it means that the namings of units needs to be updated and maybe updating 'properties' of a unit?
Hey guys
i wanted to ask which units are currently available. Because in my project i would need units like centimeters, meters, kilometers, m-per-sec, km-per-hours, m-per-sec2 and some others. Are these examples currently available?
Kind regards Phil