Class PathIntent


  • @Beta
    public class PathIntent
    extends ConnectivityIntent
    Abstraction of explicitly path specified connectivity intent.
    • Constructor Detail

      • PathIntent

        protected PathIntent​(ApplicationId appId,
                             Key key,
                             TrafficSelector selector,
                             TrafficTreatment treatment,
                             Path path,
                             java.util.List<Constraint> constraints,
                             int priority,
                             PathIntent.ProtectionType type,
                             ResourceGroup resourceGroup)
        Creates a new point-to-point intent with the supplied ingress/egress ports and using the specified explicit path, which can be classified as PRIMARY or BACKUP.
        Parameters:
        appId - application identifier
        key - intent key
        selector - traffic selector
        treatment - treatment
        path - traversed links
        constraints - optional list of constraints
        priority - priority to use for the generated flows
        type - PRIMARY or BACKUP
        resourceGroup - resource group for this intent
        Throws:
        java.lang.NullPointerException - path is null
      • PathIntent

        protected PathIntent()
        Constructor for serializer.
    • Method Detail

      • builder

        public static PathIntent.Builder builder()
        Returns a new host to host intent builder.
        Returns:
        host to host intent builder
      • validate

        public static void validate​(java.util.List<Link> links)
        Validates that source element ID and destination element ID of a link are different for the specified all links and that destination element ID of a link and source element ID of the next adjacent source element ID are same for the specified all links.
        Parameters:
        links - links to be validated
      • path

        public Path path()
        Returns the links which the traffic goes along.
        Returns:
        traversed links
      • toString

        public java.lang.String toString()
        Overrides:
        toString in class java.lang.Object