pipeline.domain.state.StateFactory

class StateFactory(observatory: str, start: datetime | None = None)[source]

Bases: object

Factory for creating observatory-specific State objects.

Creates the appropriate State subclass based on the observatory name and observation start time.

Methods

create_state

Return a State object with given ID and obs_mode.

__init__(observatory: str, start: datetime | None = None) None[source]

Initialize a StateFactory object.

Parameters:
  • observatory -- name of observatory to create State(s) for.

  • start -- start time of observation / measurement set; this is used to distinguish between Cycle 0 and later ALMA datasets.

create_state(state_id: int, obs_mode: str) State[source]

Return a State object with given ID and obs_mode.