Package com.tll.model

Examples of com.tll.model.User.addAuthority()


    // set the role as user by default
    Authority userAuth =
        dao.load(new NameKey<Authority>(Authority.class, AuthorityRoles.ROLE_USER.toString(),
            Authority.FIELDNAME_AUTHORITY));
    user.addAuthority(userAuth);

    persist(user);

    return user;
  }
View Full Code Here


    // set the user as un-locked by default
    user.setLocked(false);

    // set the role as user by default
    user.addAuthority(dao.load(new NameKey<Authority>(Authority.class, AuthorityRoles.ROLE_USER.toString(),
        Authority.FIELDNAME_AUTHORITY)));

    persist(user);

    return user;
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.