public HttpResponseMessage AgregaConsumo(DTOPeticion <DTOHistoricoCerveza> peticion)
        {
            HttpStatusCode estado = default(HttpStatusCode);

            try
            {
                CervezaLogica.AgregarHistorico(ref estado, peticion.Entidad);
                return(HTTPResponseHelp.CrearResponse <DTORespuesta
                                                       <String> >(this, new DTORespuesta <string>()
                {
                    Mensaje = "OK"
                }, estado));
            }
            catch (Exception e)
            {
                return(HTTPResponseHelp.CrearResponse <DTORespuesta <String> >(this, new DTORespuesta <string>()
                {
                    Mensaje = "Error"
                }, HttpStatusCode.InternalServerError));
            }
        }
        public HttpResponseMessage ObtenerTodo()
        {
            string         mensaje = string.Empty;
            HttpStatusCode estado  = default(HttpStatusCode);

            try
            {
                List <DTOCerveza> lst = CervezaLogica.ObtenerTodo(ref estado, ref mensaje);

                return(HTTPResponseHelp.CrearResponse <DTORespuesta
                                                       <DTOCerveza> >(this, new DTORespuesta <DTOCerveza>()
                {
                    Mensaje = mensaje, Datos = lst
                }, estado));
            }
            catch
            {
                return(HTTPResponseHelp.CrearResponse <DTORespuesta <String> >(this, new DTORespuesta <string>()
                {
                    Mensaje = "Error"
                }, HttpStatusCode.InternalServerError));
            }
        }
        public HttpResponseMessage Obtener(int id)
        {
            string         mensaje = string.Empty;
            HttpStatusCode estado  = default(HttpStatusCode);

            try
            {
                DTOCerveza token = CervezaLogica.ObtenerCerveza(ref estado, ref mensaje, id);

                return(HTTPResponseHelp.CrearResponse <DTORespuesta
                                                       <DTOCerveza> >(this, new DTORespuesta <DTOCerveza>()
                {
                    Mensaje = mensaje, Entidad = token
                }, estado));
            }
            catch
            {
                return(HTTPResponseHelp.CrearResponse <DTORespuesta <String> >(this, new DTORespuesta <string>()
                {
                    Mensaje = "Error"
                }, HttpStatusCode.InternalServerError));
            }
        }