mirror of
https://github.com/DSpace/dspace-angular.git
synced 2025-10-07 01:54:15 +00:00
Cache redesign part 2
This commit is contained in:
@@ -82,17 +82,6 @@ export const alternativeLinkIndexSelector: MemoizedSelector<CoreState, IndexStat
|
||||
(state: MetaIndexState) => state[IndexName.ALTERNATIVE_OBJECT_LINK]
|
||||
);
|
||||
|
||||
/**
|
||||
* Return the request UUID mapping index based on the MetaIndexState
|
||||
*
|
||||
* @returns
|
||||
* a MemoizedSelector to select the request UUID mapping
|
||||
*/
|
||||
export const requestUUIDIndexSelector: MemoizedSelector<CoreState, IndexState> = createSelector(
|
||||
metaIndexSelector,
|
||||
(state: MetaIndexState) => state[IndexName.UUID_MAPPING]
|
||||
);
|
||||
|
||||
/**
|
||||
* Return the self link of an object in the object-cache based on its UUID
|
||||
*
|
||||
@@ -121,21 +110,6 @@ export const uuidFromHrefSelector =
|
||||
(state: IndexState) => hasValue(state) ? state[getUrlWithoutEmbedParams(href)] : undefined
|
||||
);
|
||||
|
||||
/**
|
||||
* Return the UUID of a cached request based on the UUID of a request
|
||||
* that wasn't sent because the response was already cached
|
||||
*
|
||||
* @param uuid
|
||||
* The UUID of the new request
|
||||
* @returns
|
||||
* a MemoizedSelector to select the UUID of the cached request
|
||||
*/
|
||||
export const originalRequestUUIDFromRequestUUIDSelector =
|
||||
(uuid: string): MemoizedSelector<CoreState, string> => createSelector(
|
||||
requestUUIDIndexSelector,
|
||||
(state: IndexState) => hasValue(state) ? state[uuid] : undefined
|
||||
);
|
||||
|
||||
/**
|
||||
* Return the self link of an object based on its alternative link
|
||||
*
|
||||
|
Reference in New Issue
Block a user