Added support for link nodes in the repo filesystem driver.

Includes a patch to update existing link node file extensions from .lnk to .url, as CIFS requires .url files to generate the file:// links.


git-svn-id: https://svn.alfresco.com/repos/alfresco-enterprise/alfresco/HEAD/root@4947 c4b6b30b-aa2e-2d43-bbcb-ca4b014f7261
This commit is contained in:
Gary Spencer
2007-01-29 10:46:01 +00:00
parent 01fb4eac8a
commit 60ba6773c5
18 changed files with 892 additions and 40 deletions

View File

@@ -68,7 +68,8 @@ public class FileFolderServiceImpl implements FileFolderService
"./*" +
"[like(@cm:name, $cm:name, false)" +
" and not (subtypeOf('" + ContentModel.TYPE_SYSTEM_FOLDER + "'))" +
" and (subtypeOf('" + ContentModel.TYPE_FOLDER + "') or subtypeOf('" + ContentModel.TYPE_CONTENT + "'))]";
" and (subtypeOf('" + ContentModel.TYPE_FOLDER + "') or subtypeOf('" + ContentModel.TYPE_CONTENT + "')" +
" and (subtypeOf('" + ContentModel.TYPE_LINK + "'))]";
/** Shallow search for all files and folders */
private static final String LUCENE_QUERY_SHALLOW_ALL =
@@ -77,6 +78,7 @@ public class FileFolderServiceImpl implements FileFolderService
"+(" +
"TYPE:\"" + ContentModel.TYPE_CONTENT + "\" " +
"TYPE:\"" + ContentModel.TYPE_FOLDER + "\" " +
"TYPE:\"" + ContentModel.TYPE_LINK + "\" " +
")";
/** Shallow search for all files and folders */
@@ -96,7 +98,8 @@ public class FileFolderServiceImpl implements FileFolderService
".//*" +
"[like(@cm:name, $cm:name, false)" +
" and not (subtypeOf('" + ContentModel.TYPE_SYSTEM_FOLDER + "'))" +
" and (subtypeOf('" + ContentModel.TYPE_FOLDER + "') or subtypeOf('" + ContentModel.TYPE_CONTENT + "'))]";
" and (subtypeOf('" + ContentModel.TYPE_FOLDER + "') or subtypeOf('" + ContentModel.TYPE_CONTENT + "')" +
" and (subtypeOf('" + ContentModel.TYPE_LINK + "'))]";
/** empty parameters */
private static final QueryParameterDefinition[] PARAMS_ANY_NAME = new QueryParameterDefinition[1];
@@ -246,7 +249,8 @@ public class FileFolderServiceImpl implements FileFolderService
}
return true;
}
else if (dictionaryService.isSubClass(typeQName, ContentModel.TYPE_CONTENT))
else if (dictionaryService.isSubClass(typeQName, ContentModel.TYPE_CONTENT) ||
dictionaryService.isSubClass(typeQName, ContentModel.TYPE_LINK))
{
// it is a regular file
return false;