-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathCheckouts.java
More file actions
42 lines (30 loc) · 931 Bytes
/
Checkouts.java
File metadata and controls
42 lines (30 loc) · 931 Bytes
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
package com.example.accessingdatajpa;
import javax.persistence.Entity;
import javax.persistence.GeneratedValue;
import javax.persistence.GenerationType;
import javax.persistence.Id;
@Entity
public class Checkouts{
@Id
@GeneratedValue(strategy=GenerationType.AUTO)
private Long UserId;
private Long BookId;
private int TimeStamp;
protected Authors() {}
public Genre(Long UserId, Loong BookId, int TimeStamp) {
this.UserId = UserId;
this.BookId = BookId;
this.TimeStamp = TimeStamp;
@Override
public String toString() {
return String.format(
"Checkouts[UserId=%d, BookId='%d', TimeStamp='%d']",
FirstName, LastName);
}
public String getFirstName() {
return FirstName;
}
public String getLastName() {
return LastName;
}
}