示例#1
0
        static void Main(string[] args)
        {
            string apiurl = GetURL(args, 0, APIUrl);
            string weburl = GetURL(args, 1, WebUrl);

            Console.WriteLine("APIUrl is {1}{0}WebUrl is {2}{0}", Environment.NewLine, apiurl, weburl);

            var hits  = new SetupHitMonkey(apiurl, weburl);
            var cache = new SetupCacheMonkey(apiurl, weburl);

            var monkeys = new IMonkey[] {
                hits.HitProductAPIs(),
                cache.CacheMoviePage(),
                cache.CacheArtistPage(),
                hits.HitReviewerPage(),
                hits.HitGenrePage(),
            };

            foreach (IMonkey monkey in monkeys)
            {
                monkey.Jump();
            }

            ResultCollection.Stats();
            ResultCollection.GenerateSitemap(
                WebUrl,
                filePath: "sitemap.xml",
                seedUrl: SeedUrl
                );
            ResultCollection.SendMail();
        }
示例#2
0
    public static void Main()
    {
        Zoo <string>    zoo    = new Zoo <string> ("Boston");
        IMonkey <float> monkey = zoo.GetTheMonkey <float> (3.14F);

        monkey.Jump();
    }
示例#3
0
        static void Main(string[] args)
        {
            string apiurl = GetURL(args, 0, APIUrl);
            string weburl = GetURL(args, 1, WebUrl);
            Console.WriteLine("APIUrl is {1}{0}WebUrl is {2}{0}", Environment.NewLine, apiurl, weburl);

            var hits = new SetupHitMonkey(apiurl, weburl);
            var cache = new SetupCacheMonkey(apiurl, weburl);

            var monkeys = new IMonkey[] {
                hits.HitProductAPIs(),
                cache.CacheMoviePage(),
                cache.CacheArtistPage(),
                hits.HitReviewerPage(),
                hits.HitGenrePage(),
            };
            foreach (IMonkey monkey in monkeys)
            {
                monkey.Jump();
            }

            ResultCollection.Stats();
            ResultCollection.GenerateSitemap(
                WebUrl,
                filePath: "sitemap.xml",
                seedUrl: SeedUrl
            );
            ResultCollection.SendMail();
        }
		public DerivedSessionWithWrongArgs(IDriverEnvironment environment, IMonkey monkey) : base(environment)
		{
			Monkey = monkey;
		}
 public DerivedSessionWithWrongArgs(IDriverEnvironment environment, IMonkey monkey) : base(environment)
 {
     Monkey = monkey;
 }
示例#6
0
 public MonkeyPerson(IMonkey monkey) : base(monkey)
 {
 }
示例#7
0
 public void AddMonkey(IMonkey monkey)
 {
     _availableMonkeys.Add(monkey);
 }