Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.

Bug 316149

Summary: would like to be able to specify an acceptable tolerance for numeric differences
Product: [Eclipse Project] Platform Reporter: David L. Paterline <paterldl>
Component: CompareAssignee: Platform-Compare-Inbox <platform-compare-inbox>
Status: RESOLVED WONTFIX QA Contact:
Severity: enhancement    
Priority: P3    
Version: 3.4.1   
Target Milestone: ---   
Hardware: All   
OS: All   
Whiteboard:

Description David L. Paterline CLA 2010-06-08 10:56:21 EDT
Build Identifier: M20080911-1700

As I am doing a lot of scientific computing, I am using the compare tool for data files, some of which can be very large. To minimize the differences, I would like to be able to specify a tolerance within which a numerical difference would be ignored (or simply highlighted, rather than being called out as a difference). For example, ignore or highlight any numerical differences within 0.01% of the base value.

Reproducible: Always

Steps to Reproduce:
1. Compare any two nearly-identical data files with numerical differences.
Comment 1 Tomasz Zarna CLA 2010-06-15 07:05:35 EDT
To achieve that you will need to create your own token comparator by implementing the ITokenComparator interface. We do not plan to add such feature in Eclipse, so I guess you will also need to implement a content viewer for the data you're comparing. You can find more information on how to start here : http://help.eclipse.org/galileo/topic/org.eclipse.platform.doc.isv/guide/compare_contentviewer.htm