Property Tolerance
- Namespace
- YndigoBlue.Velocity.Data.Oracle
- Assembly
- YndigoBlue.Velocity.dll
Tolerance
Gets or sets the tolerance for spatial operations.
public float Tolerance { get; set; }
Property Value
Remarks
Tolerance is a small distance value used by Oracle's spatial operators to determine when two coordinates are considered equal. This is critical for spatial queries and operations that involve geometry comparisons.
The default value of 0.01 is appropriate for most geographical coordinate systems (latitude/longitude where coordinates are in degrees). When coordinates differ by less than the tolerance value, they are treated as identical.
Setting the Tolerance:
- Very Small Tolerances (< 0.001): Require exact coordinate matches. Useful for precise operations but may miss nearby coordinates due to floating-point precision issues. Can slow down spatial queries.
- Moderate Tolerances (0.01 - 0.1): Suitable for most geographical data at degree precision. Balances accuracy and performance.
- Larger Tolerances (> 0.1): Treats widely separated coordinates as equal. May lead to incorrect spatial relationships and should only be used when intentionally merging nearby but distinct features.
Impact on Operations: Tolerance affects spatial predicates (overlaps, contains, touches) and geometry construction operations. Incorrect tolerance can cause geometries to be incorrectly classified or merged.