INNER CODE UNIT · C#

Enclosure

BlueshiftSoftware/EntityFrameworkCore · src/Blueshift.EntityFrameworkCore.MongoDB.SampleDomain/ZooDbContext.cs:138

    public class Enclosure
    {
        // When using attribute-driven data modeling, either [BsonId] or [Key]
        // is required for the primary key field; either will work with the
        // MongoDb C# driver EFCore adapter
        [Key, DatabaseGenerated(DatabaseGeneratedOption.Identity)]
        public ObjectId EnclosureId { get; [UsedImplicitly] private set; }

        public string Name { get; set; }

        public string AnimalEnclosureType { get; set; }

        [Denormalize(nameof(Animal.Name))]
        public IList<Animal> Animals { get; [UsedImplicitly] private set; } = new List<Animal>();

        public Schedule WeeklySchedule { get; set; }

    }

View source record →

📰 Research Paper
Loading…
⏳ Fetching content…