Class DefaultPath

    • Constructor Detail

      • DefaultPath

        public DefaultPath​(ProviderId providerId,
                           java.util.List<Link> links,
                           Weight cost,
                           Annotations... annotations)
        Creates a path from the specified source and destination using the supplied list of links.
        Parameters:
        providerId - provider identity
        links - contiguous links that comprise the path
        cost - unit-less path cost
        annotations - optional key/value annotations
    • Method Detail

      • links

        public java.util.List<Link> links()
        Description copied from interface: Path
        Returns sequence of links comprising the path.
        Specified by:
        links in interface Path
        Returns:
        list of links
      • cost

        public double cost()
        Description copied from interface: Path
        Returns the path cost as a unit-less value.
        Specified by:
        cost in interface Path
        Returns:
        unit-less path cost
      • weight

        public Weight weight()
        Description copied from interface: Path
        Returns the path cost as an weight instance.
        Specified by:
        weight in interface Path
        Returns:
        weight path cost
      • equals

        public boolean equals​(java.lang.Object obj)
        Overrides:
        equals in class DefaultLink