Merged HEAD-BUG-FIX (4.3/Cloud) to HEAD (4.3/Cloud)

57035: Merged V4.2-BUG-FIX (4.2.1) to HEAD-BUG-FIX (Cloud/4.3)
      56502: Merged HEAD-BUG-FIX to V4.2-BUG-FIX (4.2.1)
         55925: <<NOT IN 4.1.6>> Merged V4.1-BUG-FIX (4.1.7) to HEAD-BUG-FIX (4.2)
            55707: Formatting during investigations of MNT-9510


git-svn-id: https://svn.alfresco.com/repos/alfresco-enterprise/alfresco/HEAD/root@61668 c4b6b30b-aa2e-2d43-bbcb-ca4b014f7261
This commit is contained in:
Alan Davis
2014-02-11 18:47:16 +00:00
parent fcd4ab8d01
commit b43564995e

View File

@@ -72,63 +72,63 @@ public class FilterSortNodeEntity
}
public String getPattern()
{
return pattern;
}
{
return pattern;
}
protected String escape(String s, char escapeChar)
{
StringBuilder sb = new StringBuilder();
int idx = -1;
int offset = 0;
do
{
idx = s.indexOf(escapeChar, offset);
if(idx != -1)
{
sb.append(s.substring(offset, idx));
sb.append("\\");
sb.append(escapeChar);
offset = idx + 1;
}
}
while(idx != -1);
sb.append(s.substring(offset));
return sb.toString();
}
protected String escape(String s, char escapeChar)
{
StringBuilder sb = new StringBuilder();
int idx = -1;
int offset = 0;
do
{
idx = s.indexOf(escapeChar, offset);
if(idx != -1)
{
sb.append(s.substring(offset, idx));
sb.append("\\");
sb.append(escapeChar);
offset = idx + 1;
}
}
while(idx != -1);
sb.append(s.substring(offset));
return sb.toString();
}
public void setPattern(String pattern)
{
if(pattern != null)
{
// escape the '%' character with '\' (standard SQL escape character)
pattern = escape(pattern, '%');
// replace the wildcard character '*' with the one used in database queries i.e. '%'
this.pattern = pattern.replace('*', '%');
}
}
public void setPattern(String pattern)
{
if(pattern != null)
{
// escape the '%' character with '\' (standard SQL escape character)
pattern = escape(pattern, '%');
// replace the wildcard character '*' with the one used in database queries i.e. '%'
this.pattern = pattern.replace('*', '%');
}
}
public void setAssocTypeQNameIds(Set<Long> assocTypeQNameIds)
{
this.assocTypeQNameIds = assocTypeQNameIds;
}
public void setAssocTypeQNameIds(Set<Long> assocTypeQNameIds)
{
this.assocTypeQNameIds = assocTypeQNameIds;
}
public Set<Long> getAssocTypeQNameIds()
{
return assocTypeQNameIds;
}
public Set<Long> getAssocTypeQNameIds()
{
return assocTypeQNameIds;
}
public Long getNamePropertyQNameId()
{
return namePropertyQNameId;
}
public Long getNamePropertyQNameId()
{
return namePropertyQNameId;
}
public void setNamePropertyQNameId(Long namePropertyQNameId)
{
this.namePropertyQNameId = namePropertyQNameId;
}
public void setNamePropertyQNameId(Long namePropertyQNameId)
{
this.namePropertyQNameId = namePropertyQNameId;
}
public NodePropertyEntity getProp1()
public NodePropertyEntity getProp1()
{
return prop1;
}