LinksHelper
The LinksHelper
class is useful to manage all the RefyLink database operations
Author
N7ghtm4r3 - Tecknobit
See also
Properties
Link copied to clipboard
protected val ATTACH_LINK_TO_COLLECTIONS_QUERY: String = "REPLACE INTO collections_links(collection_id,link_id) VALUES "
ATTACH_LINK_TO_COLLECTIONS_QUERY
the query used to attach link to collectionsLink copied to clipboard
private val ATTACH_LINK_TO_TEAMS_QUERY: String = "REPLACE INTO teams_links(team_id,link_id) VALUES "
ATTACH_LINK_TO_TEAMS_QUERY
the query used to attach link to teamsLink copied to clipboard
private val DETACH_LINK_FROM_COLLECTIONS_QUERY: String = "DELETE FROM collections_links WHERE link_id='%s' AND collection_id IN ("
DETACH_LINK_FROM_COLLECTIONS_QUERY
the query used to detach link from collectionsLink copied to clipboard
private val DETACH_LINK_FROM_TEAMS_QUERY: String = "DELETE FROM teams_links WHERE link_id='%s' AND team_id IN ("
DETACH_LINK_FROM_TEAMS_QUERY
the query used to detach link from teamsLink copied to clipboard
entityManager
entity manager helperLink copied to clipboard
linksRepository
instance for the links repositoryLink copied to clipboard
RELATIONSHIP_VALUES_SLICE
query part to insert in the join table new rowLink copied to clipboard
ROUND_BRACKET
round bracket characterLink copied to clipboard
SINGLE_QUOTE
single quote characterLink copied to clipboard
TUPLE_VALUES_SLICE
query part to insert in the join table new rowFunctions
Link copied to clipboard
Link copied to clipboard
Method to delete a link
Link copied to clipboard
Link copied to clipboard
protected open fun <I> executeInsertBatch(insertQuery: String, valuesSlice: String, values: Collection<I>, batchQuery: RefyItemsHelper.BatchQuery)
Method to execute a batch query to insert attachments
Link copied to clipboard
Method to get all the user's links, included the links shared in the teams and in the collections shared in the teams
Link copied to clipboard
Method used to get an item if the user is authorized
Link copied to clipboard
Method to get the user's owned links identifiers
Link copied to clipboard
Method to get the user's owned links
Link copied to clipboard
protected open fun manageAttachments(workflow: RefyItemsHelper.AttachmentsManagementWorkflow, itemId: String, ids: List<String>)
protected open fun manageAttachments(workflow: RefyItemsHelper.AttachmentsManagementWorkflow, valuesSlice: String, itemId: String, ids: List<String>, batchQuery: RefyItemsHelper.BatchQuery)
Method to manage the attachments of an item to a container
Link copied to clipboard
Method to manage the collections where the link is shared
Link copied to clipboard
Method to manage the teams where the link is shared