SignalBoxes

class sig_box.SignalBoxes(data_dir=None, update=False)[source]

A class for collecting signal box prefix codes.

Parameters
  • data_dir (str, None) – name of data directory, defaults to None

  • update (bool) – whether to check on update and proceed to update the package data, defaults to False

Example:

>>> from pyrcs.other_assets import SignalBoxes

>>> sb = SignalBoxes()

>>> print(sb.Name)
Signal box prefix codes

>>> print(sb.SourceURL)
http://www.railwaycodes.org.uk/signal/signal_boxes0.shtm

Methods

cdd_sigbox(*sub_dir, **kwargs)

Change directory to package data directory and sub-directories (and/or a file).

collect_non_national_rail_codes([…])

Collect signal box prefix codes of non-national rail from source web page.

collect_signal_box_prefix_codes(initial[, …])

Collect signal box prefix codes for the given initial from source web page.

fetch_non_national_rail_codes([update, …])

Fetch signal box prefix codes of non-national rail from local backup.

fetch_signal_box_prefix_codes([update, …])

Fetch signal box prefix codes from local backup.