Git Repository Public Repository

ISBets21MAUBRY

URLs

Copy to Clipboard
 
3cf4057e97448d401b49261033b8ab566105944e
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
package domain;

import java.util.Vector;

import javax.persistence.CascadeType;
import javax.persistence.Entity;
import javax.persistence.FetchType;
import javax.persistence.OneToMany;

@Entity
public class RegularUser extends User {

	private String birthDate;

	private String email;
	private String bankAccount;
	private Integer phoneNumb;

	private String address;
	private float saldo;
	@OneToMany(fetch = FetchType.EAGER, cascade = CascadeType.PERSIST)
	private Vector<Bet> bets = new Vector<Bet>();

	public RegularUser(String userName, String userPass, String firstName, String lastName, String birthDate,
			String email, String bankAccount, Integer phoneNumber, String address, float balance) {
		super(userName, userPass, firstName, lastName);
		this.birthDate = birthDate;
		this.email = email;
		this.bankAccount = bankAccount;
		this.phoneNumb = phoneNumber;
		this.address = address;
		this.saldo = balance;
	}

	public String getBirthDate() {
		return birthDate;
	}

	public void setBirthDate(String birthDate) {
		this.birthDate = birthDate;
	}

	public String getEmail() {
		return email;
	}

	public void setEmail(String email) {
		this.email = email;
	}

	public String getBankAccount() {
		return bankAccount;
	}

	public void setBankAccount(String bankAccount) {
		this.bankAccount = bankAccount;
	}

	public Integer getPhoneNumb() {
		return phoneNumb;
	}

	public void setPhoneNumb(Integer phoneNumb) {
		this.phoneNumb = phoneNumb;
	}

	public String getAddress() {
		return address;
	}

	public void setAddress(String address) {
		this.address = address;
	}

	public Float getBalance() {
		return saldo;
	}

	public void setBalance(float balance) {
		this.saldo = balance;
	}

	@Override
	public String toString() {
		String st = super.toString() + "\nbirthDate: " + birthDate + "\nemail:" + email + "\nbankAccount: "
				+ bankAccount + "\nphoneNumb: " + phoneNumb + "\naddress: " + address + "\nsaldo: " + saldo;
		return st;
	}

	public Bet addBet(Bet b) {
		bets.add(b);
		return b;
	}

	public Vector<Bet> getBets() {
		return this.bets;
	}

	public void setBets(Vector<Bet> bets) {
		this.bets = bets;
	}

}

Commits for ISBets21MAUBRYeclipse-workspace/ISBets21MAUBRY/src/main/java/domain/RegularUser.java

Diff revisions: vs.
Revision Author Commited Message
3cf405 ... porkipig Sun 16 May, 2021 19:27:29 +0000

IteraciĆ³n 3(VersiĆ³n sin idiomas)