Class DecoratingAndCompositeCondition

java.lang.Object
com.atlassian.plugin.webresource.condition.DecoratingAndCompositeCondition
All Implemented Interfaces:
com.atlassian.plugin.web.api.baseconditions.BaseCondition, com.atlassian.plugin.web.api.baseconditions.CompositeCondition<DecoratingCondition>, com.atlassian.plugin.web.baseconditions.BaseCondition, com.atlassian.plugin.web.baseconditions.CompositeCondition<DecoratingCondition>, DecoratingCondition

public class DecoratingAndCompositeCondition extends Object
Implementation of DecoratingCompositeCondition that fits the new UrlReadingCondition interface.
Since:
v3.0
  • Field Details

  • Constructor Details

    • DecoratingAndCompositeCondition

      public DecoratingAndCompositeCondition()
  • Method Details

    • shouldDisplay

      public boolean shouldDisplay(QueryParams params)
      Description copied from interface: DecoratingCondition
      Determine whether the web fragment should be displayed. This method should only read values from its config and the query params.
      Parameters:
      params - query params
      Returns:
      true if the user should see the fragment, false otherwise
    • invertCondition

      public DecoratingCondition invertCondition()
      Returns:
      a version of this condition with inverted boolean logic.
    • addCondition

      public void addCondition(DecoratingCondition condition)
      Specified by:
      addCondition in interface com.atlassian.plugin.web.api.baseconditions.CompositeCondition<DecoratingCondition>
    • addToUrl

      public void addToUrl(UrlBuilder urlBuilder, UrlBuildingStrategy urlBuilderStrategy)
      Description copied from interface: DecoratingCondition
      Called when constructing the URL as the hosting HTML page is being served. Can add parameters to the query string and alter the resource hash.
      Specified by:
      addToUrl in interface DecoratingCondition
      Parameters:
      urlBuilder - interface for contributing to the URL
    • getConditions

      public List<DecoratingCondition> getConditions()