コード例 #1
0
  public static boolean getNeedGranteeName(OperationContext octxt) {
    if (octxt == null) {
      return true;
    }

    GranteeNames data = getGranteeNames(octxt);
    if (data == null) {
      return true;
    }

    return data.needGranteeName();
  }
コード例 #2
0
  public static void setNeedGranteeName(OperationContext octxt, boolean needGranteeName) {
    if (octxt == null) return;

    GranteeNames data = getOrInitGranteeNames(octxt);
    data.setNeedGranteeName(needGranteeName);
  }
コード例 #3
0
  /**
   * bug 35079, 39804: avoid potential excessive LDAP searches for grantee names during XML encoding
   * folder ACLs
   *
   * <p>- collect grantee ids on all folder user shares of the mailbox - resolve all ids into names
   * (LDAP search if necessary) - set the ids-to-names map in the OperationContext
   *
   * @param octxt
   * @param mbox
   */
  public static void addGranteeNames(OperationContext octxt, Mailbox.FolderNode node) {
    if (octxt == null || node == null) return;

    GranteeNames data = getOrInitGranteeNames(octxt);
    data.addRootNode(node);
  }