Class ApplicationSpec

java.lang.Object
com.yahoo.messagebus.routing.ApplicationSpec

public class ApplicationSpec extends Object
This class holds the specifications of an application running message bus services. It is used for ensuring that a RoutingSpec holds valid routing specifications.
Author:
Simon Thoresen Hult
  • Constructor Details

    • ApplicationSpec

      public ApplicationSpec()
      Constructs a new instance of this class.
    • ApplicationSpec

      public ApplicationSpec(ApplicationSpec obj)
      Implements the copy constructor.
      Parameters:
      obj - The object to copy.
  • Method Details

    • add

      public ApplicationSpec add(ApplicationSpec app)
      Adds the content of the given application to this.
      Parameters:
      app - The application whose content to copy.
      Returns:
      This, to allow chaining.
    • addService

      public ApplicationSpec addService(String protocol, String name)
      Adds a service name to the list of known services.
      Parameters:
      protocol - The protocol for which to add the service.
      name - The service to add.
      Returns:
      This, to allow chaining.
    • isService

      public boolean isService(String protocol, String pattern)
      Determines whether or not the given service pattern matches any of the known services.
      Parameters:
      protocol - The protocol whose services to check.
      pattern - The pattern to match.
      Returns:
      True if at least one service was found.