Пример #1
0
        public JObject GetMaze(string name, int row, int col)
        {
            Maze maze = m.GenerateMaze(name, row, col);

            if (maze != null)
            {
                JObject obj = JObject.Parse(maze.ToJSON());
                //return new Class1(maze);
                return(obj);
            }
            return(null);
        }
Пример #2
0
        // GET: api/Single/name/rows/cols
        public JObject GetMaze(string name, int rows, int cols)
        {
            Maze    maze = singleModel.GenerateMaze(name, rows, cols);
            JObject obj  = JObject.Parse(maze.ToJSON());

            return(obj);
        }