Examples of User


Examples of pl.edu.pwr.lostinhashset.entity.User

    System.out.println("Objekt typu Address ma nadpisaną metodę .toString() i przedstawia się: \n" + address);
    System.out.println("---------------------------------------------------");
   
    User[] users = new User[3];
    System.out.println("Pusta tablica przedstawia się swoim typem i hash-kodem: \n" + users);
    users[0] = new User();
    users[1] = new User();
    users[2] = new User();
    System.out.println("Tablica zawierająca trzy elementy nadal przedstawia się swoim typem i hash-kodem: \n" + users);
    Integer[] numbers = new Integer[2];
    numbers[0] = 7;
    numbers[1] = 5;
    System.out.println("Niezależnie od tego jakiego typu obiekty zawiera: \n" + numbers);
    System.out.println("---------------------------------------------------");
   
    List<Address> addresses = new ArrayList<Address>();
    System.out.println("Pusta kolekcja przedstawia się w nawiasach kwadratowych: \n" + addresses.toString());
   
    Set<Address> addresses2 = new HashSet<Address>();
    addresses2.add(address);
    System.out.println("Na elementach kolekcji wywoływana jest metoda .toString(): \n" + addresses2);
   
    Queue<User> usersQueue = new LinkedList<User>();
    usersQueue.offer(new User());
    System.out.println(usersQueue);
    System.out.println("---------------------------------------------------");
   
    Map<String, Object> politechnika = new HashMap<String, Object>();
    politechnika.put("liczba studentów", 30000);
View Full Code Here

Examples of pl.lodz.p.cm.ctp.dao.model.User

 
  private User find(String sql, Object... values) throws DAOException {
        Connection connection = null;
        PreparedStatement preparedStatement = null;
        ResultSet resultSet = null;
        User user = null;

        try {
            connection = daoFactory.getConnection();
            preparedStatement = prepareStatement(connection, sql, false, values);
            resultSet = preparedStatement.executeQuery();
View Full Code Here

Examples of pojo.User

    String page = "login";
    if (request.getParameter("Login") != null) {
      String taikhoan = request.getParameter("taikhoan");
      String matkhau = request.getParameter("matkhau");
      UserDAO khDAO = new UserDAOImpl();
      User kh = khDAO.getUserInfo(taikhoan);
      if (kh != null && matkhau.equals(kh.getPassword())) {

        request.setAttribute("TaiKhoan", taikhoan,
            WebRequest.SCOPE_SESSION);
        request.setAttribute("HoTen", kh.getName(),
            WebRequest.SCOPE_SESSION);
        request.setAttribute("role", kh.getRole(),
            WebRequest.SCOPE_SESSION);
        page = "index";
      } else {
        model.addAttribute("info",
            "Your account and password not valid");
View Full Code Here

Examples of project.entities.User

import project.entities.User;

public class UserDAOImpl extends HibernateDaoSupport implements UserDAO {

  public User createUser(String name, String password) {
    User newUser = new User(name, password);
    return (User) getHibernateTemplate().save(newUser);
  }
View Full Code Here

Examples of project.entities.authorization.User

import project.entities.authorization.User;

public class UserDAOImpl extends HibernateDaoSupport implements UserDAO {

  public User createUser(String name, String password, int person) {
    User newUser = new User(name, password, person);
    return (User) getHibernateTemplate().save(newUser);
  }
View Full Code Here

Examples of redis.clients.johm.models.User

import redis.clients.johm.models.User;

public class SearchTest extends JOhmTestBase {
    @Test(expected = InvalidFieldException.class)
    public void cannotSearchOnNullField() {
        User user1 = new User();
        user1.setName("model1");
        user1.setRoom("tworoom");
        user1.setAge(88);
        JOhm.save(user1);

        JOhm.find(User.class, null, "foo");
    }
View Full Code Here

Examples of ru.org.linux.user.User

    if (!tmpl.isSessionAuthorized()) {
      throw new AccessViolationException("Not authorized");
    }

    User user = tmpl.getCurrentUser();

    Poll poll = pollDao.getCurrentPoll();
    Topic msg = messageDao.getById(poll.getTopicId());

    if (voteid != poll.getId()) {
View Full Code Here

Examples of ru.webcrafter.core.entities.User

            // HACKZZZ
            final String userName = principal.getName();
            UserAuth userAuth = userService.getUser(userName);
            if (userAuth != null) {
                long userId = userAuth.getUserId();
                User craftUser = service.getUser(userId);
                map.put("userCrafter", craftUser);
            }
        }

        return "craft";
View Full Code Here

Examples of sample.data.User

     * @see org.springframework.security.core.userdetails.UserDetailsService#loadUserByUsername(java.lang.String)
     */
    @Override
    public UserDetails loadUserByUsername(String username)
            throws UsernameNotFoundException {
        User user = userRepository.findByEmail(username);
        if(user == null) {
            throw new UsernameNotFoundException("Could not find user " + username);
        }
        return new CustomUserDetails(user);
    }
View Full Code Here

Examples of sample.domain.User

    private UserDAO userDAO = null;

    public UserDetails loadUserByUsername(String username)
            throws AuthenticationException {
        try {
            User user = userDAO.findByUsername(username);

            return new org.springframework.security.core.userdetails.User(user
                    .getUsername(), user.getPassword(), true, true, true, true,
                    AuthorityUtils.createAuthorityList("ROLE_USER"));
        } catch (Exception e) {
            LOG.error(e.getMessage(), e);
            throw new UsernameNotFoundException("No matching account", e);
        }
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.