for (int i = 0; i < currentLength; i++) {
updatedAuthorizedEntities[i] = firstAcl.getAuthorizedEntities()[i];
}
AuthorizedEntity authorizedEntity = new AuthorizedEntity();
authorizedEntity.setOperation(authorizedEntity.lookupOperation(op));
authorizedEntity.setEntities(new String[]{principalToAdd});
updatedAuthorizedEntities[currentLength] = authorizedEntity;
firstAcl.setAuthorizedEntities(updatedAuthorizedEntities);
}
}