Given a class...
public class Message
{
/// key: User, value: folder name
private readonly IDictionary<User, string> _folders = new Dictionary<User, string>();
public virtual IDictionary<User, string> Folders { get { return _folders; } }
}
<map name="Folders" access="field.camelcase-underscore">
<key column="Message_id" />
<index-many-to-many class="User" column="User_id" />
<element column="FolderName" type="System.String" />
</map>
Is it possible to
- Get all messages for a user
- Get all messages for a user with a specific folder name
Thanks