Package alluxio.wire
Class MasterInfo
- java.lang.Object
-
- alluxio.wire.MasterInfo
-
@NotThreadSafe public final class MasterInfo extends java.lang.Object
Master information.
-
-
Constructor Summary
Constructors Constructor Description MasterInfo()
Creates a new instance ofMasterInfo
.MasterInfo(long id, Address address)
Creates a new instance ofMasterInfo
.MasterInfo(long id, Address address, long lastUpdatedTimeMs)
Creates a new instance ofMasterInfo
.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description boolean
equals(java.lang.Object o)
Address
getAddress()
long
getId()
long
getLastUpdatedTimeMs()
int
hashCode()
MasterInfo
setAddress(Address address)
MasterInfo
setId(long id)
MasterInfo
setLastUpdatedTimeMs(long lastUpdatedTimeMs)
java.lang.String
toString()
void
updateLastUpdatedTimeMs()
Updates the last updated time of the master (in milliseconds).
-
-
-
Constructor Detail
-
MasterInfo
public MasterInfo()
Creates a new instance ofMasterInfo
.
-
MasterInfo
public MasterInfo(long id, Address address, long lastUpdatedTimeMs)
Creates a new instance ofMasterInfo
.- Parameters:
id
- the master id to useaddress
- the master address to uselastUpdatedTimeMs
- the master lastUpdatedTimeMs to use
-
MasterInfo
public MasterInfo(long id, Address address)
Creates a new instance ofMasterInfo
.- Parameters:
id
- the master id to useaddress
- the master address to use
-
-
Method Detail
-
getAddress
public Address getAddress()
- Returns:
- the master's address
-
getId
public long getId()
- Returns:
- the id of the master
-
getLastUpdatedTimeMs
public long getLastUpdatedTimeMs()
- Returns:
- the last updated time of the master in ms
-
setAddress
public MasterInfo setAddress(Address address)
- Parameters:
address
- the master address information- Returns:
- the master information
-
setId
public MasterInfo setId(long id)
- Parameters:
id
- the master id- Returns:
- the master information
-
setLastUpdatedTimeMs
public MasterInfo setLastUpdatedTimeMs(long lastUpdatedTimeMs)
- Parameters:
lastUpdatedTimeMs
- the last update time in ms- Returns:
- the master information
-
toString
public java.lang.String toString()
- Overrides:
toString
in classjava.lang.Object
-
updateLastUpdatedTimeMs
public void updateLastUpdatedTimeMs()
Updates the last updated time of the master (in milliseconds).
-
equals
public boolean equals(java.lang.Object o)
- Overrides:
equals
in classjava.lang.Object
-
hashCode
public int hashCode()
- Overrides:
hashCode
in classjava.lang.Object
-
-