I need to extend my domain model: products may have different specifications. E.g. motherboard specs are different from monitor specs.
there are two entities:
public class Product {
public Guid Id { get; set; }
public Category Category { get; set; }
// ..Price, Title, Manufacturer properties
}
where Category
is
public class Category {
// ..ctor to initialize this.Specs as List or as Dictionary
public Guid Id { get; set; }
public String Title { get; set; }
public ICollection<String> Specs { get; set; }
}
Is that a normal way to solve this I mean putting ICollection<String> Specs
inside Category
entity?
I'm using ASP.NET MVC
& Raven DB
.