예제 #1
0
파일: voidop.cs 프로젝트: nuxleus/ajaxmin
 public override void Accept(IVisitor visitor)
 {
     if (visitor != null)
     {
         visitor.Visit(this);
     }
 }
예제 #2
0
 public void Accept(IVisitor visitor)
 {
     foreach (var employee in this.employees)
     {
         employee.Accept(visitor);
     }
 }
예제 #3
0
 public override void OnVisitChildNodes(IVisitor visitor)
 {
     if (Condition != null)
         Condition.Visit(visitor);
     if (Code != null)
         Code.Visit(visitor);
 }
예제 #4
0
        private void RunInWidth(WorkFlowContext context, IVisitor visitor)
        {
            Queue<string> fila = new Queue<string>();
            List<string> mark = new List<string>();

            fila.Enqueue(context.SourceState);
            mark.Add(context.SourceState);

            while (fila.Count != 0)
            {
                string statusfila = fila.Dequeue();
                context.SourceState = statusfila;
                foreach (var item in this.GetActivities(context).OrderBy(x => x.Operation))
                {
                    context.Operation = item.Operation;
                    string newstatus = this.GetNextStatus(context);
                    visitor.Visit(statusfila, new Activity { Operation = item.Operation, Description = item.Description }, newstatus);

                    if (!mark.Contains(newstatus))
                    {
                        fila.Enqueue(newstatus);
                        mark.Add(newstatus);
                    }
                }
            }
        }
예제 #5
0
 void IAlgorithms.Accept(IVisitor visitor)
 {
     foreach (IAlgorithm a in this._lstAlgorithm)
     {
         visitor.Visit(a);
     }
 }
예제 #6
0
 public void Accept(IVisitor visitor)
 {
     foreach (var account in this.accounts)
     {
         account.Accept(visitor);
     }
 }
예제 #7
0
 public void Visit(IVisitor visitor)
 {
     foreach (var employee in this.employees)
     {
         visitor.Visit(employee);
     }
 }
예제 #8
0
 public override void AcceptVisit(IVisitor visitor)
 {
     visitor.StartVisit<ISimpleFixture>(this);
     MaterialFactory.AcceptVisit(visitor);
     ShapeFactory.AcceptVisit(visitor);
     visitor.EndVisit<ISimpleFixture>(this);
 }
예제 #9
0
        private bool Accept(IVisitor visitor, Stack<int> inStack, Stack<int> resumeStack)
        {
            if (visitor.VisitEnter(this)) {

                int firstChild = 0;

                if (resumeStack.Count > 0) {
                    firstChild = resumeStack.Pop();
                    if (resumeStack.Count == 0) {
                        // If this is the node we found last time then start looking at the next one
                        firstChild++;
                    }
                }

                for (int i = firstChild; i < Children.Count(); i++) {
                    Composite c = Children.ElementAt(i);
                    if (!c.Accept(visitor, inStack, resumeStack)) {
                        inStack.Push(i);
                        break;
                    }
                }
            }

            return visitor.VisitExit(this);
        }
예제 #10
0
 public override void OnVisitChildNodes(IVisitor visitor)
 {
     foreach (var n in Content)
     {
         n.Visit(visitor);
     }
 }
예제 #11
0
파일: Class1.cs 프로젝트: KasperSK/I4SWD
 public void Accept(IVisitor visitor)
 {
     foreach (var asset in _assets)
     {
         asset.Accept(visitor);
     }
 }
예제 #12
0
 public void AcceptVisit(IVisitor visitor)
 {
     visitor.StartVisit<ISimulator>(this);
     ActorsFactory.AcceptVisit(visitor);
     ConstraintsFactory.AcceptVisit(visitor);
     visitor.EndVisit<ISimulator>(this);
 }
		public void Accept(IVisitor visitor)
		{
			foreach (IEntity entity in Entities)
			{
				entity.Accept(visitor);
			}
		}
예제 #14
0
    public void Accept(IVisitor visitor)
    {
      AdditionVisitor addVisitor = visitor as AdditionVisitor;

      if (addVisitor != null)
        addVisitor.args[Strings.result] =  addVisitor.add();
    }
예제 #15
0
 public override void OnVisitChildNodes(IVisitor visitor)
 {
     foreach (var e in Expressions)
     {
         e.Visit(visitor);
     }
 }
예제 #16
0
        private void RunInDepth(WorkFlowContext context, IVisitor visitor)
        {
            if (string.IsNullOrEmpty(context.SourceState))
            {
                return;
            }
            else
            {
                foreach (var item in this.GetActivities(context).OrderBy(x => x.Operation))
                {
                    context.Operation = item.Operation;
                    string newstatus = this.GetNextStatus(context);
                    string laststate = context.SourceState;
                    string transition = string.Format("{0},{1},{2}", context.SourceState, item.Description, newstatus);

                    if (NotPresent(transition))
                    {
                        visitor.Visit(context.SourceState, new Activity { Operation = item.Operation, Description = item.Description }, newstatus);
                        context.SourceState = newstatus;
                        RunInDepth(context, visitor);
                        context.SourceState = laststate;
                    }
                }
            }
        }
예제 #17
0
 public GarbageCollector(List<IMemoryProfile> memoryProfiles, IVisitor visitor)
 {
     foreach (var item in memoryProfiles)
     {
         item.Accept(visitor);
     }
 }
예제 #18
0
 /**
  * Create a new Logger, which has as initial trace a sequence of
  * visiting events where the visitor <code>v</code> visits each of
  * the <code>nodes</code>
  */
 public Logger(IVisitor v, IVisitable[] nodes)
 {
     for (int i = 0; i < nodes.Length; i++)
     {
         log( new Event(v, nodes[i]) );
     }
 }
예제 #19
0
        public void Accept(IVisitor visitor)
        {
            visitor.VisitScene(this);

            foreach (IVisitable childScene in this.ChildGraphs)
                childScene.Accept(visitor);
        }
예제 #20
0
 public override void OnVisitChildNodes(IVisitor visitor)
 {
     foreach (var kp in Values)
     {
         kp.Value.Visit(visitor);
     }
 }
예제 #21
0
 public RangeTripsView()
 {
     InitializeComponent();
     _gridUI = new RangeTripGridVisibilityManager(_panel1, new ToolStripItemsVisibilityManager(_toolStrip1, _toolStripItemsForGrid));
     _newRangeTripUI = new RangeTripControlVisibilityManager(_panel1, new ToolStripItemsVisibilityManager(_toolStrip1, _toolStripItemsForAddNewUI));
     _showDatabaseLocation = new ShowDatabaseInStatusBarVisitor(_databaseLocationStatusLabel.Name);
 }
예제 #22
0
 public void Accept(IVisitor visitor)
 {
     foreach (Employee e in _employees)
     {
         e.Accept(visitor);
     }
     Console.WriteLine();
 }
예제 #23
0
 public override void Accept(IVisitor<BaseObject> visitor)
 {
     var ourSectionVisitor = visitor as IVisitor<StringsSection>;
     if (ourSectionVisitor != null)
     {
         ourSectionVisitor.Visit(this);
     }
 }
예제 #24
0
 public override void Accept(IVisitor<BaseObject> visitor)
 {
     var ourObjectVisitor = visitor as IVisitor<DestinationFile>;
     if (ourObjectVisitor != null)
     {
         ourObjectVisitor.Visit(this);
     }
 }
예제 #25
0
 public override void Accept(IVisitor<BaseObject> visitor)
 {
     var ourObjectVisitor = visitor as IVisitor<Shortcut>;
     if (ourObjectVisitor != null)
     {
         ourObjectVisitor.Visit(this);
     }
 }
예제 #26
0
 public void Accept(IVisitor visitor)
 {
     foreach (var part in this._parts)
     {
         part.Accept(visitor);
     }
     visitor.Visit(this);
 }
예제 #27
0
 public override void OnVisitChildNodes(IVisitor visitor)
 {
     foreach (var e in Values)
     {
         if (e!=null)
             e.Visit(visitor);
     }
 }
예제 #28
0
파일: Visitor.cs 프로젝트: fathurxzz/aleqx
 public void Accept(IVisitor visitor)
 {
     visitor.Visit(this);
     foreach (var floor in Floors)
     {
         floor.Accept(visitor);
     }
 }
예제 #29
0
파일: Group.cs 프로젝트: gobixm/learn
 public void Accept(IVisitor visitor)
 {
     visitor.VisitGroup(this);
     foreach (IUnit unit in SubUnits)
     {
         unit.Accept(visitor);
     }
 }
 public override void Accept(IVisitor<BaseObject> visitor)
 {
     var ourSectionVisitor = visitor as IVisitor<DestinationRegValuesSection>;
     if (ourSectionVisitor != null)
     {
         ourSectionVisitor.Visit(this);
     }
 }
예제 #31
0
 public void Accept(IVisitor pVisitor)
 {
     pVisitor.Visit(this);
 }
 public virtual void Accept(IVisitor visitor)
 {
     visitor.Visit((dynamic)this);
 }
예제 #33
0
 public override void VisitChildren(IVisitor visitor)
 {
     Body.Visit(visitor);
     EnforcedReturnType.Visit(visitor);
 }
예제 #34
0
 public abstract void AcceptVisit(IVisitor visitor);
예제 #35
0
 public override void Accept(IVisitor visitor)
 {
     Values = VisitAndReplace(Values, visitor);
 }
예제 #36
0
 public void Init()
 {
     this._visitorCollection = VisitorCollection.CreateInstance();
     this._visitor           = new ObjectTypeVisitor(this._visitorCollection);
     this._strategy          = new CamelCaseNamingStrategy();
 }
 public void Accept(IVisitor visitor)
 {
     visitor.Visit(this); //double dispatching
 }
예제 #38
0
 public void Accept(IVisitor v)
 {
     v.Visit(this);
 }
예제 #39
0
 public void Accept(IVisitor visitor)
 {
     visitor.VisitEmployees(this);
 }
예제 #40
0
 public void Accept(IVisitor person)
 {
     person.TreatmentEmployee(this);
 }
예제 #41
0
 public override void AcceptVisitor(IVisitor Visitor)
 {
     Visitor.Visit(this);
 }
예제 #42
0
 public override void Accept(IVisitor visitor)
 {
     visitor.VisitDynamicText(this);
 }
예제 #43
0
 public void Accept(IVisitor visitor)
 {
     visitor.VisitEnter(this);
     Arg.Accept(visitor);
     visitor.VisitLeave(this);
 }
예제 #44
0
 public override Object Accept(IVisitor v, Object o)
 {
     return(v.Visit(this, o));
 }
예제 #45
0
 public override void Visit(IVisitor visitor) => visitor.VisitRoot(this);
예제 #46
0
 public abstract override void accept(IVisitor v);
예제 #47
0
 public abstract void Accept(IVisitor visitor, NodeBase child);
예제 #48
0
 public override void Accept(IVisitor visitor, Function function, Module mod)
 {
     visitor.Visit(this, function, mod);
 }
예제 #49
0
 /// <summary>
 /// Accepts the specified visitor.
 /// </summary>
 /// <param name="visitor">The visitor.</param>
 public void Accept(IVisitor visitor)
 {
     visitor.OnProduction(this);
 }
예제 #50
0
 public void Accept(IVisitor visitor)
 {
     visitor.VisitCustomerCommand(this);
 }
예제 #51
0
 public override string Accept(IVisitor visitor)
 {
     return(visitor.Visit(this));
 }
예제 #52
0
 public void Accept(IVisitor visitor)
 {
     visitor.VisitPurchaseOrderCommand(this);
 }
예제 #53
0
 public void Init()
 {
     this._visitorCollection = new VisitorCollection();
     this._visitor           = new UInt16TypeVisitor(this._visitorCollection);
     this._strategy          = new CamelCaseNamingStrategy();
 }
예제 #54
0
 public void Accept(IVisitor visitor)
 {
     visitor.VisitSalesOrderCommand(this);
 }
 public override void accept(IVisitor v)
 {
     v.imprimeArchivo(this);
 }
예제 #56
0
 protected override T VisitNode <T>(IVisitor <T> visitor)
 {
     return(visitor.Visit(this));
 }
예제 #57
0
 public void Accept(IVisitor visitor)
 {
     visitor.Visit(this);
 }
예제 #58
0
 public override void Visit(IVisitor visitor)
 {
     visitor.Accept(this);
 }
예제 #59
0
 public override void Accept(IVisitor visitor)
 {
     visitor.VisitBook(this);
 }
예제 #60
0
 public void AcceptVisit(IVisitor visitor)
 {
     visitor.Visit <IConvexHullOfPointsShape>(this);
 }