Package net.sourceforge.guacamole.net.auth.mysql.model

Examples of net.sourceforge.guacamole.net.auth.mysql.model.UserExample.createCriteria()


     */
    public MySQLUser retrieveUser(String name) {

        // Query user by ID
        UserExample example = new UserExample();
        example.createCriteria().andUsernameEqualTo(name);
        List<UserWithBLOBs> users = userDAO.selectByExampleWithBLOBs(example);

        // If no user found, return null
        if(users.isEmpty())
            return null;
View Full Code Here


        if (credentials.getUsername() == null)
            return null;

        // Query user
        UserExample userExample = new UserExample();
        userExample.createCriteria().andUsernameEqualTo(credentials.getUsername());
        List<UserWithBLOBs> users = userDAO.selectByExampleWithBLOBs(userExample);

        // Check that a user was found
        if (users.isEmpty())
            return null;
View Full Code Here

        // Map of all names onto their corresponding IDs
        Map<String, Integer> names = new HashMap<String, Integer>();

        // Get all users having the given IDs
        UserExample example = new UserExample();
        example.createCriteria().andUser_idIn(ids);
        List<User> users =
                userDAO.selectByExample(example);

        // Produce set of names
        for (User user : users)
View Full Code Here

        // Map of all names onto their corresponding IDs
        Map<Integer, String> names = new HashMap<Integer, String>();

        // Get all users having the given IDs
        UserExample example = new UserExample();
        example.createCriteria().andUser_idIn(Lists.newArrayList(ids));
        List<User> users =
                userDAO.selectByExample(example);

        // Produce set of names
        for (User user : users)
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.