1 |
9190add5
|
Vojtěch Bartička
|
using Core.Entities;
|
2 |
|
|
using Models.Enums;
|
3 |
|
|
using Models.Tags;
|
4 |
|
|
using Models.Users;
|
5 |
055ef5b5
|
Vojtěch Bartička
|
using System;
|
6 |
|
|
using System.Collections.Generic;
|
7 |
|
|
using System.Linq;
|
8 |
|
|
using System.Text;
|
9 |
|
|
using System.Threading.Tasks;
|
10 |
|
|
|
11 |
|
|
namespace Core.Services.TagService
|
12 |
|
|
{
|
13 |
|
|
public interface ITagService
|
14 |
|
|
{
|
15 |
a35cb648
|
Vojtěch Bartička
|
/// <summary>
|
16 |
|
|
/// Returns a tree-like structure with tag categories, tags, and subtags
|
17 |
|
|
/// </summary>
|
18 |
|
|
/// <param name="userRole">Role is used to discriminate categories available to admins only</param>
|
19 |
|
|
/// <returns></returns>
|
20 |
2c8d08af
|
Vojtěch Bartička
|
public TagTreeResponse GetTagTree(ERole userRole);
|
21 |
a35cb648
|
Vojtěch Bartička
|
/// <summary>
|
22 |
|
|
/// Creates a new category
|
23 |
|
|
/// </summary>
|
24 |
|
|
/// <param name="request"></param>
|
25 |
addbcd33
|
Vojtěch Bartička
|
public void CreateCategory(CreateCategoryRequest request);
|
26 |
a35cb648
|
Vojtěch Bartička
|
/// <summary>
|
27 |
|
|
/// Deleted a category by Id
|
28 |
|
|
/// </summary>
|
29 |
|
|
/// <param name="categoryId"></param>
|
30 |
addbcd33
|
Vojtěch Bartička
|
public void DeleteCategory(Guid categoryId);
|
31 |
a35cb648
|
Vojtěch Bartička
|
/// <summary>
|
32 |
|
|
/// Updates a category by Id
|
33 |
|
|
/// </summary>
|
34 |
|
|
/// <param name="request"></param>
|
35 |
|
|
/// <param name="categoryId"></param>
|
36 |
addbcd33
|
Vojtěch Bartička
|
public void UpdateCategory(ModifyCategoryRequest request, Guid categoryId);
|
37 |
a35cb648
|
Vojtěch Bartička
|
/// <summary>
|
38 |
|
|
/// Creates a new tag
|
39 |
|
|
/// </summary>
|
40 |
|
|
/// <param name="request"></param>
|
41 |
162db5f6
|
Vojtěch Bartička
|
public void CreateTag(CreateTagRequest request);
|
42 |
a35cb648
|
Vojtěch Bartička
|
/// <summary>
|
43 |
|
|
/// Delete tag by Id
|
44 |
|
|
/// </summary>
|
45 |
|
|
/// <param name="tagId"></param>
|
46 |
162db5f6
|
Vojtěch Bartička
|
public void DeleteTag(Guid tagId);
|
47 |
a35cb648
|
Vojtěch Bartička
|
/// <summary>
|
48 |
|
|
/// Update tag by Id
|
49 |
|
|
/// </summary>
|
50 |
|
|
/// <param name="request"></param>
|
51 |
|
|
/// <param name="tagId"></param>
|
52 |
162db5f6
|
Vojtěch Bartička
|
public void UpdateTag(ModifyTagRequest request, Guid tagId);
|
53 |
a35cb648
|
Vojtěch Bartička
|
/// <summary>
|
54 |
|
|
/// Create a subtag
|
55 |
|
|
/// </summary>
|
56 |
|
|
/// <param name="request"></param>
|
57 |
1a65a2c2
|
Vojtěch Bartička
|
public void CreateSubTag(CreateSubTagRequest request);
|
58 |
a35cb648
|
Vojtěch Bartička
|
/// <summary>
|
59 |
|
|
/// Delete subtag by Id
|
60 |
|
|
/// </summary>
|
61 |
|
|
/// <param name="subtagId"></param>
|
62 |
1a65a2c2
|
Vojtěch Bartička
|
public void DeleteSubTag(Guid subtagId);
|
63 |
a35cb648
|
Vojtěch Bartička
|
/// <summary>
|
64 |
|
|
/// Update subtag by Id
|
65 |
|
|
/// </summary>
|
66 |
|
|
/// <param name="request"></param>
|
67 |
|
|
/// <param name="subtagId"></param>
|
68 |
1a65a2c2
|
Vojtěch Bartička
|
public void UpdateSubTag(ModifySubTagRequest request, Guid subtagId);
|
69 |
a35cb648
|
Vojtěch Bartička
|
/// <summary>
|
70 |
|
|
/// Adds a note to tag's instance
|
71 |
|
|
/// </summary>
|
72 |
|
|
/// <param name="annotationId">Annotation</param>
|
73 |
|
|
/// <param name="occurrenceId">Id of the Tag</param>
|
74 |
|
|
/// <param name="user">User that's doing the adding</param>
|
75 |
|
|
/// <param name="request"></param>
|
76 |
|
|
/// <param name="isFinal">Whether the annotationId is for a FinalAnnotation or Annotation</param>
|
77 |
83d4581e
|
Vojtěch Bartička
|
public void AddNoteToTagInstance(Guid annotationId, Guid occurrenceId, User user, AddNoteToTagOccurenceRequest request, bool isFinal);
|
78 |
055ef5b5
|
Vojtěch Bartička
|
}
|
79 |
|
|
}
|