view flys-client/src/main/java/de/intevation/flys/client/shared/model/FacetRecord.java @ 524:ba238f917b94

The theme list information stored in the attribute of a collection is read and added in form of Themes and ThemeLists to the Collection. flys-client/trunk@2003 c6561f87-3c4e-4783-a992-168aeb5c3f6f
author Ingo Weinzierl <ingo.weinzierl@intevation.de>
date Wed, 25 May 2011 13:42:04 +0000
parents 0785a8ba5e6d
children 5277f46a63c2
line wrap: on
line source
package de.intevation.flys.client.shared.model;

import com.smartgwt.client.widgets.grid.ListGridRecord;

import de.intevation.flys.client.shared.model.Facet;


/**
 * @author <a href="mailto:ingo.weinzierl@intevation.de">Ingo Weinzierl</a>
 */
public class FacetRecord extends ListGridRecord {

    protected boolean active;

    protected Theme   theme;


    public FacetRecord(Theme theme) {
        this.theme = theme;

        setActive(theme.isActive());
        setName(theme.getFacet());
    }


    public Theme getTheme() {
        return theme;
    }


    public void setName(String name) {
        // TODO Add a setter method setName() to Facet
        // facet.setName(name);
        setAttribute("name", name);
    }


    public String getName() {
        return getAttribute("name");
    }


    public boolean getActive() {
        return getAttributeAsBoolean("active");
    }


    public void setActive(boolean active) {
        this.active = active;
        setAttribute("active", active);
    }
}
// vim:set ts=4 sw=4 si et sta sts=4 fenc=utf8 :

http://dive4elements.wald.intevation.org