Package loxia.model

Examples of loxia.model.InnerUser


  @Autowired
  private InnerUserDao userDao;
 
  @Test
  public void testUserDaoAdd(){
    InnerUser user = new InnerUser();
    user.setId(1l);
    user.setLoginName("user");
    user.setPassword("loxia");
    user.setUserName("Loxia User");
    userDao.save(user);
    System.out.println("==============================0");
    InnerUser u = userDao.getByPrimaryKey(1l);
    assert u != null : "user is null";
    assert u.getLoginName().equals("user") : "wrong user";
    System.out.println("==============================1");
    u.setUserName("Dragon");
    userDao.save(u);
    System.out.println("==============================2");
    u = userDao.getByPrimaryKey(1l);
    assert u.getUserName().equals("Dragon") : "wrong user name";
    userDao.findUserCount();
    System.out.println("==============================3");
    user = new InnerUser();
    user.setId(1l);
    user.setLoginName("user");
    user.setPassword("loxia");
    user.setUserName("Loxia User");
    userDao.save(user);
    System.out.println("==============================4");
    List<InnerUser> users = userDao.findUsers(new Sort[]{new Sort("u.userName")});   
    u = userDao.findUserByLoginName("user");
    Pagination<InnerUser> p = userDao.findByLoginNameP(0, 20, "user");
    System.out.println(p.getCount());
    System.out.println(users.size());
    System.out.println(u.getUserName());
    List<InnerUser> anoUsers = userDao.findUserByName(0, 20, "U", new Sort[]{new Sort("u.userName")});
    System.out.println(anoUsers.size());
    System.out.println(userDao.findByLoginName(0, 20, null).size());
    System.out.println(userDao.findByLoginName(0, 20, "a").size());
    userDao.findByLoginNameSql(0, 20, "u", null, null);
View Full Code Here


  private InnerUserDao userDao;
 
  @Test
  public void testUserDaoAdd(){
    System.out.println(Arrays.asList(userDao.getClass().getInterfaces()));
    InnerUser user = new InnerUser();
    user.setId(1l);
    user.setLoginName("user");
    user.setPassword("loxia");
    user.setUserName("Loxia User");
    userDao.save(user);
    System.out.println("==============================0");
    InnerUser u = userDao.getByPrimaryKey(1l);
    assert u != null : "user is null";
    assert u.getLoginName().equals("user") : "wrong user";
    System.out.println("==============================1");
    u.setUserName("Dragon");
    userDao.save(u);
    System.out.println("==============================2");
    u = userDao.getByPrimaryKey(1l);
    assert u.getUserName().equals("Dragon") : "wrong user name";
    userDao.findUserCount();
    System.out.println("==============================3");
    user = new InnerUser();
    user.setId(1l);
    user.setLoginName("user");
    user.setPassword("loxia");
    user.setUserName("Loxia User");
    userDao.save(user);
    System.out.println("==============================4");
    List<InnerUser> users = userDao.findUsers(new Sort[]{new Sort("u.userName")});   
    u = userDao.findUserByLoginName("user");
    Pagination<InnerUser> p = userDao.findByLoginNameP(0, 20, "user");
    System.out.println(p.getCount());
    System.out.println(users.size());
    System.out.println(u.getUserName());
    List<InnerUser> anoUsers = userDao.findUserByName(0, 20, "U", new Sort[]{new Sort("u.userName")});
    System.out.println(anoUsers.size());
    System.out.println(userDao.findByLoginName(0, 20, null).size());
    System.out.println(userDao.findByLoginName(0, 20, "a").size());
    userDao.findByLoginNameSql(0, 20, "u", null, null);
View Full Code Here

TOP

Related Classes of loxia.model.InnerUser

Copyright © 2018 www.massapicom. 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.