code: public String switchUser(CmsObject cms, HttpServletRequest req, CmsUser user) throws CmsException {
  
          return switchUserFromSession(cms, req, user, null);
      }
docs: Switches the current user to the given user. The session info is rebuild as if the given user
  performs a login at the workplace.
  
  @param cms the current CmsObject
  @param req the current request
  @param user the user to switch to
  
  @return the direct edit target if available
  
  @throws CmsException if something goes wrong