view flys-artifacts/src/main/java/de/intevation/flys/artifacts/model/WKmsImpl.java @ 1131:effe8f945c93

Create WMSLayerFacets for the WSPLGEN results after we have started a WSPLGEN job. flys-artifacts/trunk@2646 c6561f87-3c4e-4783-a992-168aeb5c3f6f
author Ingo Weinzierl <ingo.weinzierl@intevation.de>
date Mon, 05 Sep 2011 16:08:19 +0000
parents 0cb1a70b8b92
children 588798ef4791
line wrap: on
line source
package de.intevation.flys.artifacts.model;

import gnu.trove.TDoubleArrayList;

public class WKmsImpl
extends      NamedObjectImpl
implements   WKms
{
    protected TDoubleArrayList kms;
    protected TDoubleArrayList ws;

    public WKmsImpl() {
        super("");
        kms = new TDoubleArrayList();
        ws  = new TDoubleArrayList();
    }

    public WKmsImpl(int capacity) {
        super("");
        kms = new TDoubleArrayList(capacity);
        ws  = new TDoubleArrayList(capacity);
    }

    public WKmsImpl(TDoubleArrayList kms, TDoubleArrayList ws) {
        this(kms, ws, "");
    }

    public WKmsImpl(
        TDoubleArrayList kms,
        TDoubleArrayList ws,
        String           name
    ) {
        super(name);
        this.kms = kms;
        this.ws  = ws;
    }

    public void add(double km, double w) {
        kms.add(km);
        ws .add(w);
    }

    public double getW(int index) {
        return ws.getQuick(index);
    }

    public double getKm(int index) {
        return kms.getQuick(index);
    }

    public int size() {
        return kms.size();
    }
}
// vim:set ts=4 sw=4 si et sta sts=4 fenc=utf-8 :

http://dive4elements.wald.intevation.org