Interface ResourceEntry.OperationalStrategy
- Enclosing interface:
ResourceEntry
public static interface ResourceEntry.OperationalStrategy
A Operational Strategy type for the supplied
ResourceEntry
. This performs the operations on the
underlying ResourceEntry
.-
Method Summary
Modifier and TypeMethodDescriptiondefault boolean
doDelete
(ResourceEntry entry) Performs the operation to clear this entry and return it to nascent state.default Optional
<ResourceContents> Specifies how theResourceEntry
loads contents.default Optional
<ResourceId> doFindResourceId
(ResourceEntry entry) Finds theResourceId
for theResourceEntry
.Gets the immutable reverse links from theResourceEntry
default boolean
doIsOriginalContent
(ResourceEntry entry) Returns true if the content is the original content.default boolean
Returns true if the content is the original content.default boolean
doLink
(ResourceEntry entry, Path toLink) Specifies how theResourceEntry
unlinks from the whole view of the snapshot.default boolean
doUnlink
(ResourceEntry entry, Path toUnlink) Specifies how theResourceEntry
unlinks from the whole view of the snapshot.default ResourceContents
doUpdateResourceContents
(ResourceEntry resourceEntry) Specifies how theResourceEntry
updates contents.
-
Method Details
-
doIsOriginalContent
Returns true if the content is the original content.- Parameters:
entry
- theResourceEntry
- Returns:
- true if the content is original
-
doIsOriginalReversePaths
Returns true if the content is the original content.- Parameters:
entry
- theResourceEntry
- Returns:
- true if the content is original
-
doFindResourceId
Finds theResourceId
for theResourceEntry
.- Returns:
- the
Optional<ResourceId>
containing aResourceId
, or empty value
-
doLink
Specifies how theResourceEntry
unlinks from the whole view of the snapshot.- Parameters:
entry
- the entrytoLink
- the path to unlink- Returns:
- true if the linking was successful, false otherwise
-
doUnlink
Specifies how theResourceEntry
unlinks from the whole view of the snapshot.- Parameters:
entry
- the entrytoUnlink
- the path to unlink- Returns:
- true if the unlinking was successful, false otherwise
-
doUpdateResourceContents
Specifies how theResourceEntry
updates contents. -
doFindResourceContents
Specifies how theResourceEntry
loads contents.- Parameters:
entry
- the entry- Returns:
- the
ReadableByteChannel
-
doGetReversePathsImmutable
Gets the immutable reverse links from theResourceEntry
- Parameters:
entry
- the entry- Returns:
- a
Set<Path>
indicating the reverse linkags of thisResourceEntry
-
doDelete
Performs the operation to clear this entry and return it to nascent state.- Parameters:
entry
- the entry to clear
-