All Downloads are FREE. Search and download functionalities are using the official Maven repository.

org.bidib.wizard.dmx.client.model.DmxNode Maven / Gradle / Ivy

The newest version!
package org.bidib.wizard.dmx.client.model;

import java.util.ArrayList;
import java.util.List;

import org.bidib.wizard.api.model.NodeInterface;
import org.bidib.wizard.model.dmx.DmxChannel;

import com.jgoodies.binding.beans.Model;

public class DmxNode extends Model {

    private static final long serialVersionUID = 1L;

    public static final String PROPERTY_CONFIGURED_CHANNELS = "configuredChannels";

    private final List configuredChannels = new ArrayList<>();

    private final NodeInterface node;

    public DmxNode(final NodeInterface node) {
        this.node = node;
    }

    /**
     * @return the configuredChannels
     */
    public List getConfiguredChannels() {
        return configuredChannels;
    }

    /**
     * @param configuredChannels
     *            the configuredChannels to set
     */
    public void setConfiguredChannels(List configuredChannels) {

        List oldValue = new ArrayList<>(this.configuredChannels);

        // assign new list of channels
        this.configuredChannels.clear();
        this.configuredChannels.addAll(configuredChannels);

        firePropertyChange(PROPERTY_CONFIGURED_CHANNELS, oldValue, this.configuredChannels);
    }

}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy