Ejemplo n.º 1
0
        public void CreateRelation(FlowElement origin, FlowElement destination)
        {
            Relation relation = new Relation();

            relation.origin      = origin;
            relation.destination = destination;

            relations.Add(relation);
        }
Ejemplo n.º 2
0
        public List <FlowElement> GetNextElements(FlowElement element)
        {
            List <FlowElement> nextElements = new List <FlowElement>();

            foreach (Relation relation in relations)
            {
                if (relation.origin == element)
                {
                    nextElements.Add(relation.destination);
                }
            }

            return(nextElements);
        }
Ejemplo n.º 3
0
        public List <FlowElement> GetPreviousElements(FlowElement element)
        {
            List <FlowElement> previousElements = new List <FlowElement>();

            foreach (Relation relation in relations)
            {
                if (relation.destination == element)
                {
                    previousElements.Add(relation.origin);
                }
            }

            return(previousElements);
        }
Ejemplo n.º 4
0
 public void AddElement(FlowElement element)
 {
     elements.Add(element);
 }