view gnv-artifacts/src/main/java/de/intevation/gnv/artifacts/GNVArtifactFactory.java @ 473:a6a33ef35809

Added support to step back to previous states. Add state names to xform nodes in describe document and append old targets to list of reachable targets. gnv-artifacts/trunk@539 c6561f87-3c4e-4783-a992-168aeb5c3f6f
author Ingo Weinzierl <ingo.weinzierl@intevation.de>
date Wed, 13 Jan 2010 23:10:56 +0000
parents 70df44021a9f
children c0504976e606
line wrap: on
line source
package de.intevation.gnv.artifacts;

import de.intevation.artifactdatabase.DefaultArtifactFactory;
import de.intevation.artifactdatabase.ProxyArtifact;
import de.intevation.artifacts.Artifact;
import de.intevation.gnv.artifacts.fis.FISSelectArtifact;

import org.apache.log4j.Logger;

/**
 * @author Ingo Weinzierl <ingo.weinzierl@intevation.de>
 */
public class GNVArtifactFactory extends DefaultArtifactFactory {

    private static Logger logger = Logger.getLogger(GNVArtifactFactory.class);

    public GNVArtifactFactory() {
    }

    @Override
    public Artifact createArtifact(String identifier, Object context) {
        Artifact artifact = super.createArtifact(identifier, context);

        if (artifact instanceof ProxyArtifact) {
            FISSelectArtifact select = new FISSelectArtifact();
            select.setup(identifier, this, context);

            ((ProxyArtifact) artifact).setProxied(select);
        }

        return artifact;
    }
}
// vim:set ts=4 sw=4 si et sta sts=4 fenc=utf8:

http://dive4elements.wald.intevation.org