teichmann@5844: /* Copyright (C) 2011, 2012, 2013 by Bundesanstalt für Gewässerkunde teichmann@5844: * Software engineering by Intevation GmbH teichmann@5844: * teichmann@5992: * This file is Free Software under the GNU AGPL (>=v3) teichmann@5844: * and comes with ABSOLUTELY NO WARRANTY! Check out the teichmann@5992: * documentation coming with Dive4Elements River for details. teichmann@5844: */ teichmann@5844: teichmann@5829: package org.dive4elements.river.importer.parsers.tim; sascha@4732: sascha@4732: import java.util.Comparator; sascha@4732: sascha@4732: public class LexiComparator implements Comparator { sascha@4732: sascha@4732: public static final LexiComparator CMP = new LexiComparator(); sascha@4732: sascha@4732: @Override sascha@4732: public int compare(Coordinate a, Coordinate b) { sascha@4732: if (a.x < b.x) return -1; sascha@4732: if (a.x > b.x) return +1; sascha@4732: if (a.y < b.y) return -1; sascha@4732: if (a.y > b.y) return +1; sascha@4732: return 0; sascha@4732: } sascha@4732: } sascha@4732: // vim:set ts=4 sw=4 si et sta sts=4 fenc=utf8 :