Package com.yahoo.messagebus.routing
Class ApplicationSpec
java.lang.Object
com.yahoo.messagebus.routing.ApplicationSpec
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 Summary
ConstructorDescriptionConstructs a new instance of this class.Implements the copy constructor. -
Method Summary
Modifier and TypeMethodDescriptionadd
(ApplicationSpec app) Adds the content of the given application to this.addService
(String protocol, String name) Adds a service name to the list of known services.boolean
Determines whether or not the given service pattern matches any of the known services.
-
Constructor Details
-
ApplicationSpec
public ApplicationSpec()Constructs a new instance of this class. -
ApplicationSpec
Implements the copy constructor.- Parameters:
obj
- The object to copy.
-
-
Method Details
-
add
Adds the content of the given application to this.- Parameters:
app
- The application whose content to copy.- Returns:
- This, to allow chaining.
-
addService
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
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.
-