-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathWriteFileEvent.java
More file actions
32 lines (26 loc) · 889 Bytes
/
WriteFileEvent.java
File metadata and controls
32 lines (26 loc) · 889 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
package unimelb.bitbox;
// Records related information to write a file.
// A FileWriterThread object accepts this event to issue
// FILE_BYTES_REQUESTs and write the file.
public class WriteFileEvent {
//Records the file content source peer info.
public String host;
public int port;
//FILE_CREATE_REQUEST or FILE_MODIFY_REQUEST
public String request;
public String pathName;
//fileDescriptor
public String md5;
public long lastModified;
public long fileSize;
public WriteFileEvent(String host, int port, String request, String pathName,
String md5, long lastModified, long fileSize) {
this.host = host;
this.port = port;
this.request = request;
this.pathName = pathName;
this.md5 = md5;
this.lastModified = lastModified;
this.fileSize = fileSize;
}
}