Package org.symphonyoss.s2.fugue.pubsub
Class TopicSubscriptionAdmin.AbstractBuilder<T extends TopicSubscriptionAdmin.AbstractBuilder<T,B>,B extends ISubscriptionAdmin>
- java.lang.Object
-
- org.symphonyoss.s2.common.fluent.Fluent<T>
-
- org.symphonyoss.s2.common.fluent.BaseAbstractBuilder<T,B>
-
- org.symphonyoss.s2.fugue.pubsub.AbstractSubscription.AbstractBuilder<T,B>
-
- org.symphonyoss.s2.fugue.pubsub.TopicSubscriptionAdmin.AbstractBuilder<T,B>
-
- Type Parameters:
T- The concrete type of the builder for fluent methods.B- The type of the built object.
- All Implemented Interfaces:
org.symphonyoss.s2.common.fluent.IBuilder<T,B>,org.symphonyoss.s2.common.fluent.IFluent<T>
- Direct Known Subclasses:
TopicSubscription.Builder,TopicSubscriptionAdmin.Builder
- Enclosing class:
- TopicSubscriptionAdmin
public abstract static class TopicSubscriptionAdmin.AbstractBuilder<T extends TopicSubscriptionAdmin.AbstractBuilder<T,B>,B extends ISubscriptionAdmin> extends AbstractSubscription.AbstractBuilder<T,B>
AbstractBuilder.- Author:
- Bruce Skingle
-
-
Field Summary
-
Fields inherited from class org.symphonyoss.s2.fugue.pubsub.AbstractSubscription.AbstractBuilder
nameFactory_
-
-
Constructor Summary
Constructors Modifier Constructor Description protectedAbstractBuilder(Class<T> type)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected voidvalidate(org.symphonyoss.s2.common.fault.FaultAccumulator faultAccumulator)TwithServiceId(String serviceId)Set the serviceId of the topic owner.TwithSubscriptionId(String subscriptionId)Set the optional subscriptionId.TwithTopicIds(String... topicIds)Add the given topic IDs to the list of topics to be subscribed to.-
Methods inherited from class org.symphonyoss.s2.fugue.pubsub.AbstractSubscription.AbstractBuilder
withNameFactory
-
-
-
-
Method Detail
-
withSubscriptionId
public T withSubscriptionId(String subscriptionId)
Set the optional subscriptionId. The subscription (or queue in the case of SNS/SQS) will be named using the service name of the topic owner and the subscriber. In the case where a single subscribing service requires more than one subscription an additional subscription ID is needed to distinguish the multiple subscriptions.- Parameters:
subscriptionId- The subscription ID.- Returns:
- This (fluent method).
-
withServiceId
public T withServiceId(String serviceId)
Set the serviceId of the topic owner. Defaults to the service ID in the provided nameFactory.- Parameters:
serviceId- The serviceId of the topic owner.- Returns:
- This (fluent method).
-
withTopicIds
public T withTopicIds(String... topicIds)
Add the given topic IDs to the list of topics to be subscribed to.- Parameters:
topicIds- topic IDs to the list of topics to be subscribed to.- Returns:
- This (fluent method).
-
validate
protected void validate(org.symphonyoss.s2.common.fault.FaultAccumulator faultAccumulator)
- Overrides:
validatein classAbstractSubscription.AbstractBuilder<T extends TopicSubscriptionAdmin.AbstractBuilder<T,B>,B extends ISubscriptionAdmin>
-
-