teichmann@5863: /* Copyright (C) 2011, 2012, 2013 by Bundesanstalt für Gewässerkunde teichmann@5863: * Software engineering by Intevation GmbH teichmann@5863: * teichmann@5994: * This file is Free Software under the GNU AGPL (>=v3) teichmann@5863: * and comes with ABSOLUTELY NO WARRANTY! Check out the teichmann@5994: * documentation coming with Dive4Elements River for details. teichmann@5863: */ teichmann@5863: teichmann@5831: package org.dive4elements.river.artifacts.model; rrenkert@5764: rrenkert@5764: rrenkert@5764: public class StaticMorphoWidthCacheKey rrenkert@5764: { rrenkert@5764: public static final String CACHE_NAME = "morpho-width-table-static"; rrenkert@5764: rrenkert@5764: private int width_id; rrenkert@5764: rrenkert@5764: public StaticMorphoWidthCacheKey( rrenkert@5764: int width_id rrenkert@5764: ) { rrenkert@5764: this.width_id = width_id; rrenkert@5764: } rrenkert@5764: rrenkert@5764: @Override rrenkert@5764: public int hashCode() { rrenkert@5764: return (String.valueOf(width_id)).hashCode(); rrenkert@5764: } rrenkert@5764: rrenkert@5764: @Override rrenkert@5764: public boolean equals(Object other) { rrenkert@5764: if (!(other instanceof StaticMorphoWidthCacheKey)) { rrenkert@5764: return false; rrenkert@5764: } rrenkert@5764: StaticMorphoWidthCacheKey o = (StaticMorphoWidthCacheKey) other; rrenkert@5764: return this.width_id == o.width_id; rrenkert@5764: } rrenkert@5764: }