Package org.alfresco.filesys.alfresco
Class ShuffleCacheImpl
- java.lang.Object
-
- org.alfresco.filesys.alfresco.ShuffleCacheImpl
-
- All Implemented Interfaces:
ShuffleCache
public class ShuffleCacheImpl extends java.lang.Object implements ShuffleCache
Cache for alfresco "CIFS shuffles"
-
-
Constructor Summary
Constructors Constructor Description ShuffleCacheImpl()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidcreateTemporaryFile(java.lang.String path)Add a new temporary file to the "shuffle cache".booleanisCaseSensitive()booleanisCreated(java.lang.String path)Has the path been "soft created"booleanisDeleted(java.lang.String path)Has the path been "soft deleted"booleanisShuffleDirectory(java.lang.String dir)Does the specified directory contain a shuffled temporary filevoidrenameTemporaryFile(java.lang.String oldPath, java.lang.String newPath)Takes the contents of a temporary file and applies it to the new path.voidsetCaseSensitive(boolean caseSensitive)voidsoftDelete(java.lang.String path)Soft delete a file.
-
-
-
Method Detail
-
createTemporaryFile
public void createTemporaryFile(java.lang.String path)
Description copied from interface:ShuffleCacheAdd a new temporary file to the "shuffle cache". Content is not persisted in the alfresco repo until either a rename occurs or after a time delay.- Specified by:
createTemporaryFilein interfaceShuffleCache
-
softDelete
public void softDelete(java.lang.String path)
Description copied from interface:ShuffleCacheSoft delete a file. The file may be re-instated later or the delete made permenant after a time delay.- Specified by:
softDeletein interfaceShuffleCache
-
renameTemporaryFile
public void renameTemporaryFile(java.lang.String oldPath, java.lang.String newPath)Description copied from interface:ShuffleCacheTakes the contents of a temporary file and applies it to the new path.If the new path has been soft deleted then the soft delete is removed.
After the contents of the temporary file have been written the it may may be made available for garbage collection.
- Specified by:
renameTemporaryFilein interfaceShuffleCache- Parameters:
oldPath- the location of the temporaryFilenewPath- the location of the new file.
-
isShuffleDirectory
public boolean isShuffleDirectory(java.lang.String dir)
Description copied from interface:ShuffleCacheDoes the specified directory contain a shuffled temporary file- Specified by:
isShuffleDirectoryin interfaceShuffleCache- Parameters:
dir- String- Returns:
- boolean
-
isDeleted
public boolean isDeleted(java.lang.String path)
Description copied from interface:ShuffleCacheHas the path been "soft deleted"- Specified by:
isDeletedin interfaceShuffleCache
-
isCreated
public boolean isCreated(java.lang.String path)
Description copied from interface:ShuffleCacheHas the path been "soft created"- Specified by:
isCreatedin interfaceShuffleCache- Parameters:
path- String- Returns:
- boolean
-
setCaseSensitive
public void setCaseSensitive(boolean caseSensitive)
-
isCaseSensitive
public boolean isCaseSensitive()
-
-