public class UiHost extends UiNode
LAYER_DEFAULT, LAYER_OPTICAL, LAYER_PACKET
Constructor and Description |
---|
UiHost(UiTopology topology,
Host host)
Creates a new UI host.
|
Modifier and Type | Method and Description |
---|---|
Host |
backingHost()
Returns the host instance backing this UI host.
|
UiLinkId |
edgeLinkId()
Returns the identifier for the edge link between this host and
the device to which it is connected.
|
HostId |
id()
Returns the identity of the host.
|
String |
idAsString()
Returns a string representation of the element identifier.
|
DeviceId |
locationDevice()
Returns the identifier of the device to which the host is connected.
|
PortNumber |
locationPort()
Returns the port number of the device to which the host is connected.
|
RegionId |
regionId()
Returns the identifier of the region to which this device belongs.
|
void |
setEdgeLinkId(UiLinkId id)
Sets the ID of the edge link between this host and the device to which
it connects.
|
void |
setLocation(DeviceId deviceId,
PortNumber port)
Sets the host's current location.
|
void |
setRegionId(RegionId regionId)
Sets the ID of the region to which this device belongs.
|
String |
toString() |
public UiHost(UiTopology topology, Host host)
topology
- parent topologyhost
- backing hostpublic HostId id()
public RegionId regionId()
public void setRegionId(RegionId regionId)
regionId
- region identifierpublic String idAsString()
UiElement
idAsString
in class UiElement
public void setLocation(DeviceId deviceId, PortNumber port)
deviceId
- ID of deviceport
- port numberpublic void setEdgeLinkId(UiLinkId id)
id
- edge link identifier to setpublic Host backingHost()
public UiLinkId edgeLinkId()
public DeviceId locationDevice()
public PortNumber locationPort()