Skip to content

Commit be73d5a

Browse files
authored
Create Document.java
1 parent bb01270 commit be73d5a

File tree

1 file changed

+32
-0
lines changed

1 file changed

+32
-0
lines changed

Java/Document.java

Lines changed: 32 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,32 @@
1+
package ml;
2+
3+
import java.io.Serializable;
4+
5+
/**
6+
* Simple class that represents an unlabeled document
7+
*/
8+
public class Document implements Serializable {
9+
private long id;
10+
private String text;
11+
12+
public Document(long id, String text) {
13+
this.id = id;
14+
this.text = text;
15+
}
16+
17+
public long getId() {
18+
return id;
19+
}
20+
21+
public void setId(long id) {
22+
this.id = id;
23+
}
24+
25+
public String getText() {
26+
return text;
27+
}
28+
29+
public void setText(String text) {
30+
this.text = text;
31+
}
32+
}

0 commit comments

Comments
 (0)