Look up a user or group, given an ID, and return an object implementing the
O.group(), this function does not perform a type check on the returned object, so can be used where an ID may refer to a group or a user. This can be useful when working with
WorkUnit objects which can be actioned by a user or a group.
Look up the security principal with this ID. An exception will be thrown if the principal does not exist.
Look up the security principal with the
ref property set to this
null will be returned if no such principal exists.
If more than one principal has this
ref, your code should not rely on which one is returned.