001package jmri.jmrix.nce.networkdriver;
002
003/**
004 * Definition of objects to handle configuring an NCE layout connection via a
005 * NetworkDriverAdapter object.
006 *
007 * @author Bob Jacobsen Copyright (C) 2001, 2003
008 */
009public class ConnectionConfig extends jmri.jmrix.AbstractNetworkConnectionConfig {
010
011    public final static String NAME = "Network Interface";
012
013    /**
014     * Ctor for an object being created during load process; Swing init is
015     * deferred.
016     * @param p SerialPortAdapter for existing adapter
017     */
018    public ConnectionConfig(jmri.jmrix.NetworkPortAdapter p) {
019        super(p);
020    }
021
022    /**
023     * Ctor for a functional Swing object with no existing adapter
024     */
025    public ConnectionConfig() {
026        super();
027    }
028
029    @Override
030    public String name() {
031        return NAME;
032    }
033   // String manufacturerName = jmri.jmrix.DCCManufacturerList.NCE;
034
035    // public String getManufacturer() { return manufacturerName; }
036    // public void setManufacturer(String manu) { manufacturerName=manu; }
037
038    /**
039     * {@inheritDoc}
040     */
041    @Override
042    protected void setInstance() {
043        if (adapter == null) {
044            adapter = new NetworkDriverAdapter();
045        }
046    }
047
048}