Martin or anyone else that can help, I'm working on getting Units hooked up with the WPS parser. I've made a binding to hook it into the javax.units stuff. I've run into a problem parsing a string unit (ie: "meters") and getting the right Unit object for it. Basically I'm parsing a describe process response document, which lists the valid units for the return types. So for instance it lists:
<ows:UOM>meters</ows:UOM> <ows:UOM>feet</ows:UOM> To start with, it looks like the javax.units parsers/formatters will only recongnize "m" for meters, and not "meters" or "meter" or "metre". At first I thought I could make a quick reflection tool to look through the javax.units.SI class fields and match the field name "METER" (minus the s) to find the Unit I wanted. But I've since realized there are other similar problems for things like feet and foot that won't match the field names. Basically, is there already some sort of alias lookup tool for this sort of thing? Jody mentioned that we are moving to a new version of the units stuff soon (though what I've seen about it online still doesn't seem to have any sort of alias lookup). Should I bother trying to make and maintain an alias map for these sorts of things now, or should I wait until the new units code is in place first? Thanks. -- Graham Davis Refractions Research Inc. [EMAIL PROTECTED] ------------------------------------------------------------------------- This SF.net email is sponsored by: Microsoft Defy all challenges. Microsoft(R) Visual Studio 2008. http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/ _______________________________________________ Geotools-devel mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/geotools-devel
