Exemplo n.º 1
0
        public IHttpActionResult GetPainting(int id)
        {
            Painting Painting = repo.Get(id);

            if (Painting == null)
            {
                return(NotFound());
            }

            return(Ok(Painting));
        }
Exemplo n.º 2
0
        public IHttpActionResult GetPainting(int id)
        {
            _logger.Write("Get painting was called", LogLevel.INFO);
            Painting painting = _pr.Get(id);

            if (painting == null)
            {
                return(NotFound());
            }

            return(Ok(painting));
        }
Exemplo n.º 3
0
 // GET: api/Paintings/5
 public Painting Get(int id)
 {
     logger.Write("GET for paintings with id " + id, LogLevel.INFO);
     return(paintingsRepository.Get(id));
 }
Exemplo n.º 4
0
 // GET: api/Paintings/5
 public Painting Get(int id)
 {
     return(db.Get(id));
 }
Exemplo n.º 5
0
 // GET api/values/5
 public Painting Get(int id)
 {
     _logger.Write("GET for Paintings was called", LogLevel.Info);
     return(repo.Get(id));
 }