[OSM-dev] Osmosis Replication Statistics
Brett Henderson
brett at bretth.com
Sat Sep 1 09:13:02 BST 2007
Martijn van Oosterhout wrote:
>> 1
>>
> The actual number is irrelevent, it's the spacing that's important. I
> extended the script so that if you prefix it by an "!" it becomes a
> negative selection.
>
Not quite sure what you mean when you say the spacing is important. How
do I determine if the number is the start of a polygon point or if it is
a header? Is one indented and the other not, or should I just count the
number of tokens on a line?
On the negative selection point, do you mean you'd create a section like
this to exclude an area?
!5
-0.6450E+01 0.4980E+02
-0.2000E+01 0.4890E+02
END
>> -0.6450E+01 0.4980E+02
>> -0.2000E+01 0.4890E+02
>>
>
> These are normal scientific notation number. The standard
> text-to-float conversion should be able to read it just fine. It
> doesn't have to be exactly that format by the way, just about any
> number format will do.
>
Cool, it should be okay then. The default java output for positive
decimal numbers happens to look like this:
1.23456789E9
Note the lack of sign on the exponent. Java appears to be fairly
flexible in the default parsing of double numbers and handles parsing
the perl examples so should be fine.
> Currently you can't omit the begin and end markers. Not sure why we
> should make it possible either...
>
Excellent, I won't allow it either.
Finally, what precedence order do overlapping polygons have in the
file? If I have a positive area (one without the !) overlapping with a
negative area, is it the order in the file that takes precedence or do
negative areas always take precedence. The java.awt.geom.Area class
appears to be quite powerful and should allow fairly complex Area
arithmetic to be performed.
Cheers,
Brett
More information about the dev
mailing list