public World <State> WithRules(RuleSet <State> rules) { return(new World <State>(Cells, Bounds, Neighborhood, rules)); }
public World(IEnumerable <State> states, Bounds bounds, INeighborhood neighborhood, RuleSet <State> rules) { Cells = states.Select((st, i) => new Cell <State>(st, IndexToPosition(i))); Bounds = bounds; Neighborhood = neighborhood; Rules = rules; }
public World(IEnumerable <Cell <State> > cells, Bounds bounds, INeighborhood neighborhood, RuleSet <State> rules) { Cells = cells; Bounds = bounds; Neighborhood = neighborhood; Rules = rules; }
public void SetRules(RuleSet <State> ruleset) { Rules = ruleset; }