public void Add(GoalRelaxedTo annotation) { if (GoalRelaxedToAnnotations.ContainsKey(annotation.Identifier)) { throw new ArgumentException(string.Format("Goal RelaxedTo annotation identifier already exist: {0}", annotation.Identifier)); } GoalRelaxedToAnnotations.Add(annotation.Identifier, annotation); }
public override void Handle(Goal element, ParsedRelaxedToAttribute attribute, KAOSModel model) { var relaxedTo = new GoalRelaxedTo(model, element.Identifier, attribute.ObstacleIdentifier, fb.BuildFormula(attribute.Formula)); if (!model.obstacleRepository.ObstacleExists(attribute.ObstacleIdentifier)) { model.Add(new Obstacle(model) { Identifier = attribute.ObstacleIdentifier, Implicit = true }); } model.Add(relaxedTo); }
public void Add(GoalRelaxedTo providedNotAnnotation) { this.goalRepository.Add(providedNotAnnotation); }