/** * Returns the primary principal for a Subject - that is, in Portofino, the result of authenticating with * Security.groovy, which typically is a map of user properties as loaded from the database or other authentication * sources. * @param s the subject * @return the principal. */ public static Object getPrimaryPrincipal(Subject s) { return getPrincipal(s, 0); }
/** * Returns the primary principal for a Subject - that is, in Portofino, the username. * @param s the subject * @return the username. */ public static Object getPrimaryPrincipal(Subject s) { return getPrincipal(s, 0); }
/** * Wrapper for ShiroUtils.getPrincipal(Subject, int) */ public Object getPrincipal(int index) { return ShiroUtils.getPrincipal(getSubject(), index); }
/** * Wrapper for ShiroUtils.getPrincipal(Subject, int) */ public Object getPrincipal(int index) { return ShiroUtils.getPrincipal(getSubject(), index); }