Example #1
0
        public string GetResponse(FoodContext ctx)
        {
            string key = GetKey(ctx);

            if (responses.ContainsKey(key))
            {
                return(responses[key]);
            }
            else
            {
                return(GetRandomResponse());
            }
        }
Example #2
0
 public string GetKey(FoodContext ctx)
 {
     return(GetKey(ctx.userid, ctx.time, ctx.weather));
 }