Can I used Uomo from a regular java project? [message #1469535] |
Tue, 11 November 2014 12:46  |
Eclipse User |
|
|
|
Hi all,
I'm currently investigating java libraries to use in our application for validation of units and conversion of quantities.
I've had a good read through the tutorial and documentation and all looks good. When I went to actually try writing some code I ran into a bit of an issue. I'm integrating uomo into a pre existing java project which isn't a plugin project. I'm used to downloading the jars that I need, and including them through the build path config in eclipse. I've been looking around for a few hours now and can't seem to find a way to do this with uomo.
Is there a static jar file that I can link to, or does my project have to be a plugin project for this to work?
This is a cross post from my question on stackoverflow (which may or may not contain more information about my situation).
/questions/26870068/how-to-use-eclipse-uomo-units-of-measurement-in-standalone-project
Thanks for any help.
|
|
|
Re: Can I used Uomo from a regular java project? [message #1473364 is a reply to message #1469535] |
Fri, 14 November 2014 10:07  |
Eclipse User |
|
|
|
Just to update. To do this I've created a plugin project as per the tutorial (which doesn't quite seem to work for 0.7/kepler, had to wangle my way to get something that compiles). From there I used fatjar to bundle everything together into one jar. It's early days but this seems to work. My main question is, why isn't the project released like this as standard (not criticising, I'm just not sure if what I'm doing is correct or expected, but it feels like it's the way most people would want to use it?).
This is a bit of a side question, but is the documentation up to date? I'm using 0.7 and the documentation has the following line used to parse strings:
Unit<Length> metre = Unit.valueOf("m").asType(Length.class);
However the Unit class doesn't appear to have the method 'valueOf'.
Thanks
|
|
|
Powered by
FUDForum. Page generated in 0.03821 seconds