Examples of User


Examples of com.alibaba.dubbo.config.api.User

            try {
                // say name
                Assert.assertEquals("Generic Haha", demoService.sayName("Haha"));
                // get users
                List<User> users = new ArrayList<User>();
                users.add(new User("Aaa"));
                users = demoService.getUsers(users);
                Assert.assertEquals("Aaa", users.get(0).getName());
                // throw demo exception
                try {
                    demoService.throwDemoException();
View Full Code Here

Examples of com.alibaba.dubbo.examples.generic.api.IUserService.User

    public static void main(String[] args) throws Exception {
        String config = GenericConsumer.class.getPackage().getName().replace('.', '/') + "/generic-consumer.xml";
        ClassPathXmlApplicationContext context = new ClassPathXmlApplicationContext(config);
        context.start();
        IUserService userservice = (IUserService) context.getBean("userservice");
        User user = userservice.get(new Params("a=b"));
        System.out.println(user);
        System.in.read();
    }
View Full Code Here

Examples of com.alibaba.dubbo.registry.common.domain.User

    @Autowired
    RegistryServerSync registryServerSync;

    public void execute(HttpSession session, Context context, CookieParser parser) {
       
        User user = (User) session.getAttribute(WebConstants.CURRENT_USER_KEY);
        if (user != null) context.put("operator", user.getUsername());
       
        RootContextPath rootContextPath = new RootContextPath(request.getContextPath());
        context.put("rootContextPath", rootContextPath);
        if (! context.containsKey("bucLogoutAddress")) {
          context.put("bucLogoutAddress", rootContextPath.getURI("logout"));
View Full Code Here

Examples of com.alibaba.otter.shared.common.model.user.User

    @Resource(name = "userService")
    private UserService userService;

    public void doAdd(@FormGroup("addUserInfo") Group userInfo, Navigator nav,
                      @FormField(name = "formUserError", group = "addUserInfo") CustomErrors err) {
        User user = new User();
        userInfo.setProperties(user);
        user.setPassword(SecurityUtils.getPassword(user.getPassword()));
        try {
            userService.createUser(user);
        } catch (RepeatConfigureException rce) {
            err.setMessage("invalidUser");
            return;
View Full Code Here

Examples of com.alibaba.sample.petstore.dal.dataobject.User

    @Autowired
    private UserDao userDao;

    @Test
    public void getUserById() {
        User user = userDao.getUserById("j2ee");
        assertUser(user);

        user = userDao.getUserById("admin");
        assertUser(user, "admin");
    }
View Full Code Here

Examples of com.alvazan.test.db.User

    entity.setSomething("something");
    entity.setAccount(acc1);
    mgr.fillInWithKey(entity);
    // mgr.put(entity);

    User user = new User();
    user.setUuidEntity(entity);

    mgr.put(user);
    mgr.flush();

    User user2 = mgr.find(User.class, user.getId());
    Assert.assertNotNull(user2);
    Assert.assertEquals(entity.getId(), user2.getUuidEntity().getId());
  }
View Full Code Here

Examples of com.apress.progwt.client.domain.User

        this.userDAO = userDAO;
    }

    public void testGetUserByUsername() {
        String USER = "test";
        User u = userDAO.getUserByUsername(USER);
        assertEquals(USER, u.getUsername());

    }
View Full Code Here

Examples of com.apress.prospring.domain.User

    bm.saveEntry(new Entry(), null);
    performAssert();
  }

  public void testSaveComment() {
    bm.saveComment(new Comment(), new User());
    performAssert();
  }
View Full Code Here

Examples of com.architecture.core.dao.entity.User

        String queryUser = ConfigHandler.getString(Conf.RUNTIME_DB_QL_QUERY_USER);
        Map<String, Object> map = new HashMap<String, Object>();
        map.put(KEY_USERNAME, username);
        map.put(KEY_PASSWORD, password);
        User user = (User) service.queryUnique(queryUser,map);

        if (null == user) {
            throw new GlobalException(Err.USERNAME_OR_PASSWORD_ERROR);
        }else{
            return user;
View Full Code Here

Examples of com.arrgsocal.entities.User

        request.logout();
      }

      // Get the logged in user
      List<User> users = userManager.getUsers();
      User u = null;
      for (User u1 : users) {
        if (u1.getName().equals(request.getParameter("username"))) {
          u = u1;
          break;
        }
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.