/**
  * Utility helper for implementing getInterestedGroups() that returns a single-member set with the
  * group stored in data1.
  *
  * @param block
  * @return
  */
 protected Set<Group> getData1GroupAsSet(Block block) {
   Group group;
   try {
     group = EJBUtil.lookupGuid(em, Group.class, block.getData1AsGuid());
   } catch (NotFoundException e) {
     throw new RuntimeException(e);
   }
   return Collections.singleton(group);
 }
 protected User getData1User(Block block) {
   User user;
   try {
     user = EJBUtil.lookupGuid(em, User.class, block.getData1AsGuid());
   } catch (NotFoundException e) {
     throw new RuntimeException("invalid user in data1 of " + block, e);
   }
   return user;
 }
 /**
  * Utility helper for implementing getInterestedUsers() that gets everyone in the group identified
  * by the group id in data1.
  *
  * @param block
  * @return
  */
 protected final Set<User> getUsersWhoCareAboutData1Group(Block block) {
   Group group;
   try {
     group = EJBUtil.lookupGuid(em, Group.class, block.getData1AsGuid());
   } catch (NotFoundException e) {
     throw new RuntimeException("invalid group in data1 of " + block, e);
   }
   Set<User> groupMembers = groupSystem.getUserMembers(SystemViewpoint.getInstance(), group);
   return groupMembers;
 }