-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathRemotePeerInfo.java
More file actions
28 lines (25 loc) · 835 Bytes
/
RemotePeerInfo.java
File metadata and controls
28 lines (25 loc) · 835 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
/*
* CEN5501C Project2
* This is the program starting remote processes.
* This program was only tested on CISE SunOS environment.
* If you use another environment, for example, linux environment in CISE
* or other environments not in CISE, it is not guaranteed to work properly.
* It is your responsibility to adapt this program to your running environment.
*/
public class RemotePeerInfo {
public String peerId;
public String peerAddress;
public String peerPort;
public boolean hasFile;
public RemotePeerInfo(String pId, String pAddress, String pPort) {
peerId = pId;
peerAddress = pAddress;
peerPort = pPort;
}
public RemotePeerInfo(String pId, String pAddress, String pPort, int hasFile) {
peerId = pId;
peerAddress = pAddress;
peerPort = pPort;
this.hasFile = hasFile > 0;
}
}