Big honkin' merge from head. Sheesh!

git-svn-id: https://svn.alfresco.com/repos/alfresco-enterprise/alfresco/BRANCHES/WCM-DEV2/root@3617 c4b6b30b-aa2e-2d43-bbcb-ca4b014f7261
This commit is contained in:
Britt Park
2006-08-27 01:01:30 +00:00
parent e2c66899cc
commit 8031cc6574
322 changed files with 20776 additions and 6550 deletions

View File

@@ -1134,7 +1134,6 @@ public class AVMNodeService extends AbstractNodeServiceImpl implements NodeServi
* @see QName
* @see org.alfresco.service.namespace.RegexQNamePattern#MATCH_ALL
*/
@Auditable(key = Auditable.Key.ARG_0 ,parameters = {"nodeRef", "typeQNamePattern", "qnamePattern"})
public List<ChildAssociationRef> getChildAssocs(
NodeRef nodeRef,
QNamePattern typeQNamePattern,
@@ -1158,6 +1157,32 @@ public class AVMNodeService extends AbstractNodeServiceImpl implements NodeServi
return result;
}
/**
* Get a child NodeRef by name.
* @param nodeRef The parent node.
* @param assocTypeQName The type of the Child Association.
* @param childName The name of the child to get.
*/
public NodeRef getChildByName(NodeRef nodeRef, QName assocTypeQName, String childName)
{
if (!assocTypeQName.equals(ContentModel.ASSOC_CONTAINS))
{
return null;
}
Object [] avmVersionPath = AVMNodeConverter.ToAVMVersionPath(nodeRef);
try
{
AVMNodeDescriptor child = fAVMService.lookup((Integer)avmVersionPath[0],
(String)avmVersionPath[1]);
return AVMNodeConverter.ToNodeRef((Integer)avmVersionPath[0],
child.getPath());
}
catch (AVMException e)
{
return null;
}
}
/**
* Fetches the primary parent-child relationship.
* <p>