public ActionResult <IEnumerable <string> > Get(string keyword)
        {
            DiksyonaryoContext context = HttpContext.RequestServices.GetService(typeof(katagaluganAPI.DAL.DiksyonaryoContext)) as DiksyonaryoContext;
            WordEntityMysql    wordDal = new WordEntityMysql(context);

            return(wordDal.FindWord(keyword).ToArray());
        }
        public ActionResult <string> Get()
        {
            DiksyonaryoContext context = HttpContext.RequestServices.GetService(typeof(katagaluganAPI.DAL.DiksyonaryoContext)) as DiksyonaryoContext;
            WordEntityMysql    wordDal = new WordEntityMysql(context);

            return(wordDal.GetRandomWord());
        }
        public ActionResult <string> Get(int wordId)
        {
            DiksyonaryoContext   context = HttpContext.RequestServices.GetService(typeof(katagaluganAPI.DAL.DiksyonaryoContext)) as DiksyonaryoContext;
            UserDefinedWordsMyql udwDao  = new UserDefinedWordsMyql(context);
            string jsonData = JsonConvert.SerializeObject(udwDao.GetUserDefinedwords(wordId));

            return(jsonData);
        }
Esempio n. 4
0
 public UserDefinedWordsMyql(DiksyonaryoContext _context)
 {
     Context = _context;
 }
Esempio n. 5
0
 public WordEntityMysql(DiksyonaryoContext _context)
 {
     Context = _context;
 }