protected void processAcl(Acl acl, Map<String, String> headers) {
StringBuffer userGrants = new StringBuffer();
StringBuffer groupGrants = new StringBuffer();
for (Iterator<Grant> i = acl.iterator(); i.hasNext();) {
Grant grant = i.next();
if (grant.getGrantee().getType() == Grantee.GRANT_TYPE.USER) {
if (userGrants.length() > 0) {
userGrants.append(",");
}
userGrants.append(grant.toString());
} else {
if (groupGrants.length() > 0) {
groupGrants.append(",");
}
groupGrants.append(grant.toString());
}
}
headers.put("x-emc-useracl", userGrants.toString());
headers.put("x-emc-groupacl", groupGrants.toString());