@Override public User create() { User u = new User(); u.setUserId(userId); userId++; return u; }
private void writeUser(User aUser) { String date = df.format(aUser.getBirthday().getTime()); String s = "" + aUser.getUserId() + ";" + aUser.getName() + ";" + aUser.getEmail() + ";" + aUser.getGender() + ";" + date + ";" + aUser.getPassword() + ";" + aUser.getImage() + "\n"; try { writer.write(s); } catch (IOException e) { LogUtil.getLogger().error(e); } }