private Tag CreateTagIfNeeded(INoteStore note, string name, string parent = null) { if (AllTags.Any(m => m.Name == name) == false) { Tag newTag = new Tag { Name = name }; if (parent != null) { newTag.ParentGuid = parent; } newTag = note.CreateTag(newTag); allTags.Add(newTag); return(newTag); } return(AllTags.First(m => m.Name == name)); }
public NoteEventHandler(INoteStore store) => this.store = store;
public NotesController(INoteStore noteStore) { _noteStore = noteStore; }
public NotesController(ICommandSender commandSender, INoteStore store) { this.commandSender = commandSender; this.store = store; }
public NoteController( INoteStore store ) { _store = store; }
private Tag CreateTagIfNeeded(INoteStore note, string name, string parent = null) { if (AllTags.Any(m => m.Name == name) == false) { Tag newTag = new Tag { Name = name }; if (parent != null) newTag.ParentGuid = parent; newTag = note.CreateTag(newTag); allTags.Add(newTag); return newTag; } return AllTags.First(m => m.Name == name); }
public NoteCommandHandler(INoteStore store) => this.store = store;