Class OBlock

All Implemented Interfaces:
PropertyChangeListener, Comparable<NamedBean>, EventListener, PropertyChangeProvider, NamedBean, PhysicalLocationReporter

public class OBlock
extends Block
implements PropertyChangeListener
OBlock extends jmri.Block to be used in Logix Conditionals and Warrants. It is the smallest piece of track that can have occupancy detection. A better name would be Detection Circuit. However, an OBlock can be defined without an occupancy sensor and used to calculate routes.

Additional states are defined to indicate status of the track and trains to control panels. A jmri.Block has a PropertyChangeListener on the occupancy sensor and the OBlock will pass state changes of the sensor on to its warrant.

Entrances (exits when train moves in opposite direction) to OBlocks have Portals. A Portal object is a pair of OBlocks. Each OBlock has a list of its Portals.

When an OBlock (Detection Circuit) has a Portal whose entrance to the OBlock has a signal, then the OBlock and its chains of adjacent OBlocks up to the next OBlock having an entrance Portal with a signal, can be considered a "Block" in the sense of a prototypical railroad. Preferably all entrances to the "Block" should have entrance Portals with a signal.

A Portal has a list of paths (OPath objects) for each OBlock it separates. The paths are determined by the turnout settings of the turnouts contained in the block. Paths are contained within the Block boundaries. Names of OPath objects only need be unique within an OBlock.