public override bool Equals (VoyageState other) { if(object.ReferenceEquals(this, other)) return true; CompletedVoyage voyage = other as CompletedVoyage; if(null == voyage) return false; return Number.Equals(voyage.Number) && Schedule.Equals(voyage.Schedule); }
public FakeVoyage(VoyageState initialState) : base(initialState) { }
public override bool Equals (VoyageState other) { if(object.ReferenceEquals(this, other)) return true; MovingVoyage voyage = other as MovingVoyage; if(null == voyage) return false; return Number.Equals(voyage.Number) && _movementIndex == voyage._movementIndex && Schedule.Equals(voyage.Schedule); }
protected Voyage (VoyageState initialState) { if(null == initialState) throw new ArgumentNullException("initialState"); CurrentState = initialState; }