Class ItemTagRepository
java.lang.Object
org.ehrbase.repository.experimental.ItemTagRepository
Repository responsible for
ITEM_TAG persistence.-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidadminDelete(UUID targetId, ItemTagDto.ItemTagRMType targetType) voidadminDeleteAll(UUID ehrId) intbulkDelete(UUID ownerId, UUID targetVoId, ItemTagDto.ItemTagRMType targetType, Collection<UUID> ids) Bulk delete @ItemTagDtos with the givenids.bulkStore(List<ItemTagDto> itemTags) Stores the given @ItemTagDtos by performing anInsertfor tags without anItemTagDto.getId()orUpdatewith existence check for tags with anItemTagDto.getId()findForOwnerAndTarget(UUID ownerId, UUID targetVoId, ItemTagDto.ItemTagRMType targetType, Collection<UUID> ids, Collection<String> keys) Search @ItemTagDtos ofownerId, for the latest version of the giventargetVoIdby applying the optional filter forids, keys.
-
Constructor Details
-
ItemTagRepository
-
-
Method Details
-
bulkStore
Stores the given @ItemTagDtos by performing anInsertfor tags without anItemTagDto.getId()orUpdatewith existence check for tags with anItemTagDto.getId()- Parameters:
itemTags- @ItemTagDtos store usingInsertorUpdate.- Returns:
- tagIDs Sored
ItemTagDto.getId()s.
-
findForOwnerAndTarget
@Transactional public Collection<ItemTagDto> findForOwnerAndTarget(@NonNull UUID ownerId, @NonNull UUID targetVoId, @NonNull ItemTagDto.ItemTagRMType targetType, @NonNull Collection<UUID> ids, @NonNull Collection<String> keys) Search @ItemTagDtos ofownerId, for the latest version of the giventargetVoIdby applying the optional filter forids, keys.- Parameters:
ownerId- Identifier of owner object, such as EHR.targetVoId- VERSIONED_OBJECT<T> Identifier of target.targetType- Type of the target object.ids- IdentifierItemTagto search for.keys-ItemTagkeys to search for.- Returns:
- itemTags
ItemTag.
-
bulkDelete
@Transactional public int bulkDelete(@NonNull UUID ownerId, @NonNull UUID targetVoId, @NonNull ItemTagDto.ItemTagRMType targetType, @NonNull Collection<UUID> ids) Bulk delete @ItemTagDtos with the givenids.- Parameters:
ids- Identifier ofItemTagto delete.
-
adminDelete
-
adminDeleteAll
-