java.lang.Object
com.broadleafcommerce.metadata.core.domain.Route
All Implemented Interfaces:
Serializable

public class Route extends Object implements Serializable
Routes represent the relationship between a browser’s location, and the view it renders. These routes typically consist of a path, e.g. /brands, and a componentId, e.g. brands:browse. The admin client loads the entire route configuration on page load, and then uses it to route the user around the application.

Typically, routes are configured through ComponentRouteLocator. However, it's possible to create a Route similarly to an Augmentation at runtime for dynamic routes.

See Also:
  • Constructor Details

    • Route

      public Route()
  • Method Details

    • getId

      public String getId()
      Id of the route.
    • getPath

      public String getPath()
      Path matching the browser location to match to render the component.
    • getComponentKey

      public String getComponentKey()
      Key of the component to render at path.
    • getComponentName

      public String getComponentName()
      Name of the component.
    • getScopes

      public List<String> getScopes()
      Security scopes needed for a user to access the route.
    • getScopeMatchType

      public String getScopeMatchType()
      Controls how the scopes are used to filter the route's accessibility. The default is DefaultRouteScopeMatchType.ANY.
      Since:
      Admin Service 2.1.4, Release Train 2.1.5
      See Also:
    • getPredicates

      public List<RoutePredicate> getPredicates()
      Predicates that restrict access to the route.
      Since:
      Admin Services 2.3.0, Release Train 2.2.2
    • getPriority

      public int getPriority()
      The order to sort the route by. By default, routes are ordered to be last unless this field is defined explicitly.
      Since:
      Admin Services 2.3.0, Release Train 2.2.2
    • setId

      public void setId(String id)
      Id of the route.
    • setPath

      public void setPath(String path)
      Path matching the browser location to match to render the component.
    • setComponentKey

      public void setComponentKey(String componentKey)
      Key of the component to render at path.
    • setComponentName

      public void setComponentName(String componentName)
      Name of the component.
    • setScopes

      public void setScopes(List<String> scopes)
      Security scopes needed for a user to access the route.
    • setScopeMatchType

      public void setScopeMatchType(String scopeMatchType)
      Controls how the scopes are used to filter the route's accessibility. The default is DefaultRouteScopeMatchType.ANY.
      Since:
      Admin Service 2.1.4, Release Train 2.1.5
      See Also:
    • setPredicates

      public void setPredicates(List<RoutePredicate> predicates)
      Predicates that restrict access to the route.
      Since:
      Admin Services 2.3.0, Release Train 2.2.2
    • setPriority

      public void setPriority(int priority)
      The order to sort the route by. By default, routes are ordered to be last unless this field is defined explicitly.
      Since:
      Admin Services 2.3.0, Release Train 2.2.2
    • toString

      public String toString()
      Overrides:
      toString in class Object
    • equals

      public boolean equals(Object o)
      Overrides:
      equals in class Object
    • canEqual

      protected boolean canEqual(Object other)
    • hashCode

      public int hashCode()
      Overrides:
      hashCode in class Object