Class Highlights


  • public class Highlights
    extends Object
    Encapsulates highlights to be applied to the topology view, such as highlighting links, displaying link labels, perhaps even decorating nodes with badges, etc.
    • Constructor Detail

      • Highlights

        public Highlights()
    • Method Detail

      • delay

        public Highlights delay​(int ms)
        Sets the number of milliseconds to delay processing of highlights events on the client side.
        Parameters:
        ms - milliseconds to delay
        Returns:
        self, for chaining
      • delayMs

        public int delayMs()
        Return the delay for the highlight event.
        Returns:
        delay in milliseconds
      • add

        public Highlights add​(DeviceHighlight dh)
        Adds highlighting information for a device.
        Parameters:
        dh - device highlight
        Returns:
        self, for chaining
      • add

        public Highlights add​(HostHighlight hh)
        Adds highlighting information for a host.
        Parameters:
        hh - host highlight
        Returns:
        self, for chaining
      • add

        public Highlights add​(LinkHighlight lh)
        Adds highlighting information for a link.
        Parameters:
        lh - link highlight
        Returns:
        self, for chaining
      • subdueAllElse

        public Highlights subdueAllElse​(Highlights.Amount amount)
        Marks the amount by which all other elements (devices, hosts, links) not explicitly referenced here will be "subdued" visually.
        Parameters:
        amount - amount to subdue other elements
        Returns:
        self, for chaining
      • devices

        public Collection<DeviceHighlight> devices()
        Returns the collection of device highlights.
        Returns:
        device highlights
      • hosts

        public Collection<HostHighlight> hosts()
        Returns the collection of host highlights.
        Returns:
        host highlights
      • links

        public Collection<LinkHighlight> links()
        Returns the collection of link highlights.
        Returns:
        link highlights
      • subdueLevel

        public Highlights.Amount subdueLevel()
        Returns the amount by which all other elements not explicitly referenced here should be "subdued".
        Returns:
        amount to subdue other elements
      • getNode

        public NodeHighlight getNode​(String id)
        Returns the node highlight (device or host) for the given element identifier, or null if no match.
        Parameters:
        id - element identifier
        Returns:
        corresponding node highlight
      • getDevice

        public DeviceHighlight getDevice​(String id)
        Returns the device highlight for the given device identifier, or null if no match.
        Parameters:
        id - device identifier
        Returns:
        corresponding device highlight
      • getHost

        public HostHighlight getHost​(String id)
        Returns the host highlight for the given host identifier, or null if no match.
        Parameters:
        id - host identifier
        Returns:
        corresponding host highlight
      • getLink

        public LinkHighlight getLink​(String id)
        Returns the link highlight for the given link identifier, or null if no match.
        Parameters:
        id - link identifier
        Returns:
        corresponding link highlight