BolfTracker.Infrastructure.EntityFramework.ShotTypeRepository.GetById C# (CSharp) Метод

GetById() публичный Метод

public GetById ( int id ) : BolfTracker.Models.ShotType
id int
Результат BolfTracker.Models.ShotType
        public ShotType GetById(int id)
        {
            using (var context = new BolfTrackerContext())
            {
                var shotType = context.ShotTypes.SingleOrDefault(st => st.Id == id);

                return shotType;
            }
        }