mirror of
https://github.com/Alfresco/alfresco-community-repo.git
synced 2025-07-31 17:39:05 +00:00
Fixed major issues reported by sonar (Hide Utility Class Constructor)
git-svn-id: https://svn.alfresco.com/repos/alfresco-enterprise/modules/recordsmanagement/HEAD@63807 c4b6b30b-aa2e-2d43-bbcb-ca4b014f7261
This commit is contained in:
@@ -25,11 +25,16 @@ import java.util.Map;
|
|||||||
|
|
||||||
/* package scope */ class PivotUtil
|
/* package scope */ class PivotUtil
|
||||||
{
|
{
|
||||||
|
private PivotUtil()
|
||||||
|
{
|
||||||
|
// Will not be called
|
||||||
|
}
|
||||||
|
|
||||||
static Map<String, List<String>> getPivot(Map<String, List<String>> source)
|
static Map<String, List<String>> getPivot(Map<String, List<String>> source)
|
||||||
{
|
{
|
||||||
|
|
||||||
Map<String, List<String>> pivot = new HashMap<String, List<String>>();
|
Map<String, List<String>> pivot = new HashMap<String, List<String>>();
|
||||||
|
|
||||||
for(String authority : source.keySet())
|
for(String authority : source.keySet())
|
||||||
{
|
{
|
||||||
List<String>values = source.get(authority);
|
List<String>values = source.get(authority);
|
||||||
|
@@ -30,14 +30,19 @@ import org.alfresco.service.namespace.QName;
|
|||||||
|
|
||||||
/**
|
/**
|
||||||
* Utility class with policy helper methods.
|
* Utility class with policy helper methods.
|
||||||
*
|
*
|
||||||
* @author Roy Wetherall
|
* @author Roy Wetherall
|
||||||
*/
|
*/
|
||||||
public class PoliciesUtil
|
public class PoliciesUtil
|
||||||
{
|
{
|
||||||
|
private PoliciesUtil()
|
||||||
|
{
|
||||||
|
// Will not be called
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Get all aspect and node type qualified names
|
* Get all aspect and node type qualified names
|
||||||
*
|
*
|
||||||
* @param nodeRef
|
* @param nodeRef
|
||||||
* the node we are interested in
|
* the node we are interested in
|
||||||
* @return Returns a set of qualified names containing the node type and all
|
* @return Returns a set of qualified names containing the node type and all
|
||||||
@@ -51,11 +56,11 @@ public class PoliciesUtil
|
|||||||
{
|
{
|
||||||
Set<QName> qnames = null;
|
Set<QName> qnames = null;
|
||||||
try
|
try
|
||||||
{
|
{
|
||||||
Set<QName> aspectQNames = nodeService.getAspects(nodeRef);
|
Set<QName> aspectQNames = nodeService.getAspects(nodeRef);
|
||||||
|
|
||||||
QName typeQName = nodeService.getType(nodeRef);
|
QName typeQName = nodeService.getType(nodeRef);
|
||||||
|
|
||||||
qnames = new HashSet<QName>(aspectQNames.size() + 1);
|
qnames = new HashSet<QName>(aspectQNames.size() + 1);
|
||||||
qnames.addAll(aspectQNames);
|
qnames.addAll(aspectQNames);
|
||||||
qnames.add(typeQName);
|
qnames.add(typeQName);
|
||||||
@@ -67,6 +72,6 @@ public class PoliciesUtil
|
|||||||
// done
|
// done
|
||||||
return qnames;
|
return qnames;
|
||||||
}
|
}
|
||||||
}, AuthenticationUtil.getAdminUserName());
|
}, AuthenticationUtil.getAdminUserName());
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@@ -34,6 +34,11 @@ public class RmDictionaryWebServiceUtils
|
|||||||
private static final String SITE_ID = "siteId";
|
private static final String SITE_ID = "siteId";
|
||||||
private static final String SITE_PRESET = "rm-site-dashboard";
|
private static final String SITE_PRESET = "rm-site-dashboard";
|
||||||
|
|
||||||
|
private RmDictionaryWebServiceUtils()
|
||||||
|
{
|
||||||
|
// Will not be called
|
||||||
|
}
|
||||||
|
|
||||||
public static boolean isRmSite(WebScriptRequest req, SiteService siteService)
|
public static boolean isRmSite(WebScriptRequest req, SiteService siteService)
|
||||||
{
|
{
|
||||||
boolean isRmSite = false;
|
boolean isRmSite = false;
|
||||||
|
@@ -42,6 +42,11 @@ import org.apache.commons.lang.StringUtils;
|
|||||||
*/
|
*/
|
||||||
public class RequestInfoUtils
|
public class RequestInfoUtils
|
||||||
{
|
{
|
||||||
|
private RequestInfoUtils()
|
||||||
|
{
|
||||||
|
// Will not be called
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Helper method to get the service registry in order to call services
|
* Helper method to get the service registry in order to call services
|
||||||
*
|
*
|
||||||
|
Reference in New Issue
Block a user