public int compareTo(org.jclouds.s3.domain.AccessControlList.Grant o) { if (this == o) { return 0; } else { String myGranteeAndPermission = grantee.getIdentifier() + "\n" + permission; String otherGranteeAndPermission = o.grantee.getIdentifier() + "\n" + o.permission; return myGranteeAndPermission.compareTo(otherGranteeAndPermission); } }
public int compareTo(org.jclouds.s3.domain.AccessControlList.Grant o) { if (this == o) { return 0; } else { String myGranteeAndPermission = grantee.getIdentifier() + "\n" + permission; String otherGranteeAndPermission = o.grantee.getIdentifier() + "\n" + o.permission; return myGranteeAndPermission.compareTo(otherGranteeAndPermission); } }
public int compareTo(org.jclouds.s3.domain.AccessControlList.Grant o) { if (this == o) { return 0; } else { String myGranteeAndPermission = grantee.getIdentifier() + "\n" + permission; String otherGranteeAndPermission = o.grantee.getIdentifier() + "\n" + o.permission; return myGranteeAndPermission.compareTo(otherGranteeAndPermission); } }
/** * @param grantee * @param permission * @return true if the grantee has the given permission. */ public boolean hasPermission(Grantee grantee, String permission) { return hasPermission(grantee.getIdentifier(), permission); }
/** * @param grantee * @return the permissions assigned to a grantee. */ public Collection<String> getPermissions(Grantee grantee) { return getPermissions(grantee.getIdentifier()); }
/** * @param grantee * @param permission * @return true if the grantee has the given permission. */ public boolean hasPermission(Grantee grantee, String permission) { return hasPermission(grantee.getIdentifier(), permission); }
public int compareTo(org.jclouds.s3.domain.AccessControlList.Grant o) { if (this == o) { return 0; } else { String myGranteeAndPermission = grantee.getIdentifier() + "\n" + permission; String otherGranteeAndPermission = o.grantee.getIdentifier() + "\n" + o.permission; return myGranteeAndPermission.compareTo(otherGranteeAndPermission); } }
/** * @param grantee * @param permission * @return true if the grantee has the given permission. */ public boolean hasPermission(Grantee grantee, String permission) { return hasPermission(grantee.getIdentifier(), permission); }
/** * @param grantee * @return the permissions assigned to a grantee. */ public Collection<String> getPermissions(Grantee grantee) { return getPermissions(grantee.getIdentifier()); }
/** * Revoke all the permissions granted to the given grantee. * * @param grantee */ public AccessControlList revokeAllPermissions(Grantee grantee) { Collection<Grant> grantsForGrantee = findGrantsForGrantee(grantee.getIdentifier()); grants.removeAll(grantsForGrantee); return this; }
public boolean apply(Grant g) { return g.getGrantee().getIdentifier().equals(granteeId); } });
/** * @param grantee * @return the permissions assigned to a grantee. */ public Collection<String> getPermissions(Grantee grantee) { return getPermissions(grantee.getIdentifier()); }
/** * Revoke all the permissions granted to the given grantee. * * @param grantee */ public AccessControlList revokeAllPermissions(Grantee grantee) { Collection<Grant> grantsForGrantee = findGrantsForGrantee(grantee.getIdentifier()); grants.removeAll(grantsForGrantee); return this; }
/** * Revoke all the permissions granted to the given grantee. * * @param grantee */ public AccessControlList revokeAllPermissions(Grantee grantee) { Collection<Grant> grantsForGrantee = findGrantsForGrantee(grantee.getIdentifier()); grants.removeAll(grantsForGrantee); return this; }
/** * @param grantee * @param permission * @return true if the grantee has the given permission. */ public boolean hasPermission(Grantee grantee, String permission) { return hasPermission(grantee.getIdentifier(), permission); }
/** * @param grantee * @return the permissions assigned to a grantee. */ public Collection<String> getPermissions(Grantee grantee) { return getPermissions(grantee.getIdentifier()); }
/** * Revoke all the permissions granted to the given grantee. * * @param grantee */ public AccessControlList revokeAllPermissions(Grantee grantee) { Collection<Grant> grantsForGrantee = findGrantsForGrantee(grantee.getIdentifier()); grants.removeAll(grantsForGrantee); return this; }
public boolean apply(Grant g) { return g.getGrantee().getIdentifier().equals(granteeId); } });
/** * @param grantee * @param permission * @return true if the grantee has the given permission. */ public boolean hasPermission(Grantee grantee, String permission) { return hasPermission(grantee.getIdentifier(), permission); }
/** * @param grantee * @return the permissions assigned to a grantee. */ public Collection<String> getPermissions(Grantee grantee) { return getPermissions(grantee.getIdentifier()); }