Compatibility fixes

- Fixes compatibility issues with Broder's duplicate detection algorithm
- Uses Guice to call the Near-Duplicate Detection-classes, instead of the deprecated static singleton.
- Lots of refactoring of hideous code