jmri.jmrix.configurexml
Class AbstractNetworkConnectionConfigXml

java.lang.Object
  extended by jmri.configurexml.AbstractXmlAdapter
      extended by jmri.jmrix.configurexml.AbstractNetworkConnectionConfigXml
All Implemented Interfaces:
XmlAdapter
Direct Known Subclasses:
ConnectionConfigXml, ConnectionConfigXml, ConnectionConfigXml, ConnectionConfigXml, ConnectionConfigXml, ConnectionConfigXml, ConnectionConfigXml, ConnectionConfigXml

public abstract class AbstractNetworkConnectionConfigXml
extends AbstractXmlAdapter

Abstract base (and partial implementation) for classes persisting the status of Network port adapters.

Author:
Bob Jacobsen Copyright: Copyright (c) 2003

Field Summary
protected  NetworkPortAdapter adapter
           
 
Constructor Summary
AbstractNetworkConnectionConfigXml()
           
 
Method Summary
protected  void extendElement(Element e)
          Customizable method if you need to add anything more
protected abstract  void getInstance()
           
protected  void getInstance(Object object)
           
 boolean load(Element e)
          Update static data from XML file
 void load(Element element, Object o)
          Update static data from XML file
protected abstract  void register()
           
 Element store(Object o)
          Default implementation for storing the static contents of the Network port implementation
protected  void unpackElement(Element e)
          Customizable method if you need to add anything more
 
Methods inherited from class jmri.configurexml.AbstractXmlAdapter
creationErrorEncountered, getConfigXmlManager, loadDeferred, loadOrder, setConfigXmlManager
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

adapter

protected NetworkPortAdapter adapter
Constructor Detail

AbstractNetworkConnectionConfigXml

public AbstractNetworkConnectionConfigXml()
Method Detail

getInstance

protected abstract void getInstance()

register

protected abstract void register()

getInstance

protected void getInstance(Object object)

store

public Element store(Object o)
Default implementation for storing the static contents of the Network port implementation

Parameters:
o - Object to store, of type PositionableLabel
Returns:
Element containing the complete info

extendElement

protected void extendElement(Element e)
Customizable method if you need to add anything more

Parameters:
e - Element being created, update as needed

load

public boolean load(Element e)
             throws Exception
Update static data from XML file

Parameters:
e - Top level Element to unpack.
Returns:
true if successful
Throws:
Exception - when a error prevents creating the objects as as required by the input XML.

unpackElement

protected void unpackElement(Element e)
Customizable method if you need to add anything more

Parameters:
e - Element being created, update as needed

load

public void load(Element element,
                 Object o)
Update static data from XML file

Parameters:
element - Top level Element to unpack.
o - Implementation-specific Object needed for the conversion


Copyright © 1997 - 2011 JMRI Community.
JMRI, DecoderPro, PanelPro, SoundPro, DispatcherPro and associated logos are our trademarks.

Additional information on copyright, trademarks and licenses is linked here.
Site hosted by: Get JMRI Model Railroad Interface at SourceForge.net. Fast, secure and Free Open Source software downloads