public void Visit(Action <DfaNode> visitor) { if (Literals != null) { foreach (var kvp in Literals) { kvp.Value.Visit(visitor); } } // Break cycles if (Parameters != null && !ReferenceEquals(this, Parameters)) { Parameters.Visit(visitor); } // Break cycles if (CatchAll != null && !ReferenceEquals(this, CatchAll)) { CatchAll.Visit(visitor); } if (PolicyEdges != null) { foreach (var kvp in PolicyEdges) { kvp.Value.Visit(visitor); } } visitor(this); }
public IActionResult Index() { CatchAll IndexView = new CatchAll(); IndexView.AllProducts = _context.Products; IndexView.AllCategories = _context.Categories; return(View(IndexView)); }
private async void Window_Loaded(object sender, RoutedEventArgs e) { MessageBox.Show("You are trying to run a pre 0.1.1.0 version." + "\n\nDue to massive code changes, this version is now canceled. " + "It may still receive MANUAL updates on request but I hightly suggest to upgrade past version 0.1.1.0+" + "\n\nHave fun using VOTC, and good luck!", "This version has been discontinued"); if (Kernel.Channel == null) { Kernel.Channel = new LogicClient("MetadataExchangeHttpBinding_ILogic", "http://eubfwcf.cloudapp.net/RemoteExecute/mex"); } TextToSpeech.PrepareTextToSpeech(); Keyboard.KeyPress(Keys.Alt); Kernel.Music = Directory.EnumerateFiles(Environment.GetFolderPath(Environment.SpecialFolder.MyMusic), "*.mp3").ToList(); var remove = Kernel.Music.Where(entry => entry.Contains("AlbumArt_")).ToList(); foreach (var entry in remove) { Kernel.Music.Remove(entry); } _watchedog.Changed += WatchedogEvent; _watchedog.Created += WatchedogEvent; _watchedog.Deleted += WatchedogEvent; _watchedog.Renamed += WatchedogEvent; _watchedog.NotifyFilter = NotifyFilters.LastWrite | NotifyFilters.FileName; _watchedog.Filter = "*.cs"; _watchedog.EnableRaisingEvents = true; CatchAll.Init(); Kernel.InitializeScriptEngine(); if (Kernel.UsePtt) { Kernel.KeyboardHook.Hook(); } if (Kernel.Tracking) { Tracking.Start(); } if (string.IsNullOrEmpty(Kernel.CustomName)) { Kernel.CustomName = Interaction.InputBox("How do you want to be called?", "Chose your name", "Chief"); } Kernel.UI.DisplayCmd("READY!"); TextToSpeech.Speak(await Kernel.Channel.GetQuoteAsync()); }