mirror of
https://github.com/Alfresco/alfresco-community-repo.git
synced 2025-08-07 17:49:17 +00:00
Merged V3.2 to HEAD
16030: Merged V3.1 to V3.2 16001: Merged V2.2 to V3.1 15999: Temp build/test (AVM permissions - testSimpleInternalLayer) 16223: WCM UI - simple perf improvement when displaying modified list (lock icon) 16472: Merged V3.1 to V3.2 16180: ETHREEOH-2821 - fix deployment of WCM layered (ie. across web project) file 16188: WCM - minor: display (localisable) "File" text (follow-on fix for r15970) 16255: WCM - ETHREEOH-2836 16257: AVM - minor updates to unit tests 16275: WCM - ETHREEOH-2844 16277: WCM - ETHREEOH-2829 - added simple unit test 16341: AVM - minor update to reuse core (path) utils 16344: Merged V2.2 to V3.1 16323: Fix ETWOTWO-1266 (unexpected AVM conflict) 16457: Fix ETHREEOH-2836 (WCM layered files) - follow-on fix, with additional unit test 16649: Fix ETHREEOH-1878 - configure WCM locking for CIFS/FTP 16654: Merged V3.1 to V3.2 16507: Fix ETHREEOH-2604 - update unsecured-public-services-security-context.xml.sample (to allow server to start) 16527: Fix ETHREEOH-2868 - can't submit removal of WCM layered file (Older version prevents update) 16607: AVM - additional tests when deleting LD + fix to avoid cycle 16612: AVM - console improvement (lsver, rmvers) to enable admin/support to list & purge snapshots between dates 16638: Fix ETHREEOH-2893 - stale WCM/AVM layered dir 16643: AVM - console improvement (setopacity) -> eg. to set stale/modifed WCM layered folder as opaque git-svn-id: https://svn.alfresco.com/repos/alfresco-enterprise/alfresco/HEAD/root@16895 c4b6b30b-aa2e-2d43-bbcb-ca4b014f7261
This commit is contained in:
@@ -27,6 +27,7 @@ import java.io.Serializable;
|
||||
import java.util.ArrayList;
|
||||
import java.util.List;
|
||||
|
||||
import org.alfresco.repo.avm.util.AVMUtil;
|
||||
import org.alfresco.util.Pair;
|
||||
|
||||
/**
|
||||
@@ -224,7 +225,7 @@ class Lookup implements Serializable
|
||||
comp.setName(name);
|
||||
comp.setNode(node);
|
||||
if (fPosition >= 0 && fDirectlyContained &&
|
||||
fComponents.get(fPosition).getNode().getType() == AVMNodeType.LAYERED_DIRECTORY)
|
||||
getCurrentNode().getType() == AVMNodeType.LAYERED_DIRECTORY)
|
||||
{
|
||||
// if (directlyContained != ((DirectoryNode)fComponents.get(fPosition).getNode()).directlyContains(node))
|
||||
// {
|
||||
@@ -311,8 +312,7 @@ class Lookup implements Serializable
|
||||
if (fNeedsCopying)
|
||||
{
|
||||
node = node.copy(this);
|
||||
// node.setVersionID(fAVMStore.getNextVersionID());
|
||||
fComponents.get(fPosition).setNode(node);
|
||||
getCurrentLookupComponent().setNode(node);
|
||||
if (fPosition == 0)
|
||||
{
|
||||
// Inform the store of a new root.
|
||||
@@ -339,8 +339,8 @@ class Lookup implements Serializable
|
||||
*/
|
||||
private Pair<String, Integer> computeIndirection(String name)
|
||||
{
|
||||
String parentIndirection = fComponents.get(fPosition).getIndirection();
|
||||
int parentIndirectionVersion = fComponents.get(fPosition).getIndirectionVersion();
|
||||
String parentIndirection = getCurrentIndirection();
|
||||
int parentIndirectionVersion = getCurrentIndirectionVersion();
|
||||
if (parentIndirection.endsWith("/"))
|
||||
{
|
||||
return new Pair<String, Integer>(parentIndirection + name, parentIndirectionVersion);
|
||||
@@ -368,13 +368,18 @@ class Lookup implements Serializable
|
||||
}
|
||||
}
|
||||
|
||||
private LookupComponent getCurrentLookupComponent()
|
||||
{
|
||||
return fComponents.get(fPosition);
|
||||
}
|
||||
|
||||
/**
|
||||
* Get the current node we're looking at.
|
||||
* @return The current node.
|
||||
*/
|
||||
public AVMNode getCurrentNode()
|
||||
{
|
||||
return fComponents.get(fPosition).getNode();
|
||||
return getCurrentLookupComponent().getNode();
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -440,8 +445,7 @@ class Lookup implements Serializable
|
||||
*/
|
||||
public String getCurrentIndirection()
|
||||
{
|
||||
String value = fComponents.get(fPosition).getIndirection();
|
||||
return value;
|
||||
return getCurrentLookupComponent().getIndirection();
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -450,7 +454,7 @@ class Lookup implements Serializable
|
||||
*/
|
||||
public int getCurrentIndirectionVersion()
|
||||
{
|
||||
return fComponents.get(fPosition).getIndirectionVersion();
|
||||
return getCurrentLookupComponent().getIndirectionVersion();
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -480,15 +484,15 @@ class Lookup implements Serializable
|
||||
{
|
||||
if (fComponents.size() == 1)
|
||||
{
|
||||
return fStoreName + ":/";
|
||||
return AVMUtil.buildAVMPath(fStoreName, AVMUtil.AVM_PATH_SEPARATOR); // root;
|
||||
}
|
||||
StringBuilder builder = new StringBuilder();
|
||||
builder.append(fStoreName);
|
||||
builder.append(':');
|
||||
builder.append(AVMUtil.AVM_STORE_SEPARATOR_CHAR);
|
||||
int count = fComponents.size();
|
||||
for (int i = 1; i < count; i++)
|
||||
{
|
||||
builder.append('/');
|
||||
builder.append(AVMUtil.AVM_PATH_SEPARATOR_CHAR);
|
||||
builder.append(fComponents.get(i).getName());
|
||||
}
|
||||
return builder.toString();
|
||||
@@ -500,7 +504,7 @@ class Lookup implements Serializable
|
||||
*/
|
||||
public String getBaseName()
|
||||
{
|
||||
return fComponents.get(fPosition).getName();
|
||||
return getCurrentLookupComponent().getName();
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -539,4 +543,11 @@ class Lookup implements Serializable
|
||||
{
|
||||
return fVersion;
|
||||
}
|
||||
|
||||
// for debug
|
||||
@Override
|
||||
public String toString()
|
||||
{
|
||||
return getRepresentedPath();
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user