GrouperSession s, Object o, Subject subj, Field f
GrouperSession s, Group g, Subject subj, Field f
  protected static void addImmediateMembership(    GrouperSession s, Object o, Subject subj, Field f  )    throws  InsufficientPrivilegeException,            MemberAddException,            SchemaException  {    GrouperSession.validate(s);    String msg = "addImmediateMembership '" + f + "'";    GrouperLog.debug(LOG, s, msg);    try {      // The objects that will need saving      Set     objects = new LinkedHashSet();      // Who we're adding      Member  m       = PrivilegeResolver.getInstance().canViewSubject(        s, subj, msg      );      objects.add(m);      String oid = new String();      if (o.getClass().equals(Group.class)) {        ( (Group) o).setModified();        oid = ( (Group) o).getUuid();      }      else {        ( (Stem) o).setModified();        oid = ( (Stem) o).getUuid();      }      // Create the immediate membership      Membership  imm = _addMembership(s, o, m, f);      TxQueue     tx  = new TxMemberAdd(s, oid, m, f);      // Find effective memberships      Set effs = _findEffectiveMemberships(s, imm);      objects.addAll(effs);      // And then save owner and memberships      objects.add(imm);      objects.add(o);      objects.add(tx);      HibernateHelper.save(objects);      EL.addEffMembers(s, o, subj, f, effs);    }    catch (MemberAddException eMA) {      throw eMA;    }    catch (Exception e) {      throw new MemberAddException(e.getMessage());    }  } // protected static void addImmediateMembership(s, g, subj, f)