Interface HasNodeId
- All Known Implementing Classes:
NodeId,Path,ResourceId,TaskId
public interface HasNodeId
An interface which may report a
NodeId.-
Method Summary
-
Method Details
-
getNodeId
Returns aNodeIdfor this instance, throwing an exception if theNodeIdis not valid. This may return null to indicate that theNodeIdis neither valid nor invalid, but rather simply not present.- Returns:
- the
NodeIdor null. - Throws:
InvalidNodeIdException- if this instance is unable to derive aNodeId
-
getOptionalNodeId
Return andOptional<NodeId>. If this can't determine the node id, then this must return an empty instance ofOptional. UnlinkegetNodeId(), this makes no distinction between a missing and an invalid id.- Returns:
-