- Apple iPhone Air - almacsutka
- Samsung Galaxy A33 5G - a három az majdnem öt
- Motorola Edge 50 Neo - az egyensúly gyengesége
- Samsung Galaxy S25 Ultra - titán keret, acélos teljesítmény
- OFFTOPIK: Earfun-lányok Sencsenben
- Bemutatkozott a Motorola vékonymobilja
- Milyen hagyományos (nem okos-) telefont vegyek?
- Android alkalmazások - szoftver kibeszélő topik
- Huawei Watch GT 5 Pro - egészség + stílus
- 175 fotó, amit a Vivo X300 és X300 Pro kameráival készítettem
Új hozzászólás Aktív témák
-
Taoharcos
aktív tag
válasz
Taoharcos #3785 üzenetére
Ja valami kód is:
package com.corejsf;
public class User {
private String name;
private String password;
public User(String name, String password){
this.name = name;
this.password = password;
}
public String getName() {
return name;
}
public void setName(String name) {
this.name = name;
}
public String getPassword() {
return password;
}
public void setPassword(String password) {
this.password = password;
}
}package com.corejsf;
import java.io.Serializable;
import java.util.*;
import javax.faces.bean.*;
@ManagedBean(name="userbean")
@SessionScoped
public class UserBean implements Serializable{
private String name;
private String password;
private String userListToString;
private static List userList = new ArrayList();
private User user;
public String addUser(){
user = new User(name, password);
userList.add(user);
userListToString = userList.toString();
if (userList.contains(user)){
return "thankYou";
}
else {
return "loginFail";
}
}
public String loginUser(){
user = new User(name, password);
userListToString = userList.toString();
if(userList.contains(user)){
return "thankYou";
}
else{
return "loginFail";
}
}
public String getUserListToString() {
return userListToString;
}
public String getName() {
return name;
}
public void setName(String name) {
this.name = name;
}
public String getPassword() {
return password;
}
public void setPassword(String password) {
this.password = password;
}
}
Új hozzászólás Aktív témák
A topicot kiemeltem. Valaki nem akar egy nyitó hsz-t írni?:))
- Eladó egy oneplus 9 pro 256/12
- GYÖNYÖRŰ iPhone 13 Pro 128GB Graphite -1 ÉV GARANCIA - Kártyafüggetlen, MS3082
- ÁRGARANCIA! Épített KomPhone i5 13400F 16/32/64GB RAM RTX 3060 12GB GAMER PC termékbeszámítással
- LG 77C4 - 77" OLED evo - 4K 144Hz - 0.1ms - NVIDIA G-Sync - FreeSync - HDMI 2.1 - 1000 Nits
- Lenovo Thinkpad Tablet X1 Gen 3
Állásajánlatok
Cég: NetGo.hu Kft.
Város: Gödöllő
Cég: Laptopműhely Bt.
Város: Budapest