I'm writing my first NHibernate application, but I guess this question applies to any ORM framework. My application is a simple bug tracker (devs all understand the problem domain, right?), and I'm wondering how best to model the Project/Ticket relationship in the DAL. A Project has multiple Tickets; a Ticket must be owned by a Project.
Every example I've seen shows an IRepository<T>, with FindAll, Save, Delete, etc. So I have an interface IProjectRepository : IRepository<Project>.
My question comes from the following: Do I have an ITicketRepository, which knows how to talk about tickets, or is this something that the IProjectRepository needs to know about?
Or am I barking completely up the wrong tree? Can someone point me at some example code that models a parent-child relationship with a DAL?