Class ImmutableWebhookCreate.Builder

  • Enclosing class:
    ImmutableWebhookCreate

    @NotThreadSafe
    public static final class ImmutableWebhookCreate.Builder
    extends Object
    Builds instances of type ImmutableWebhookCreate. Initialize attributes and then invoke the build() method to create an immutable instance.

    Builder is not thread-safe and generally should not be stored in a field or collection, but instead used immediately to create instances.

    • Method Detail

      • from

        @CanIgnoreReturnValue
        public final ImmutableWebhookCreate.Builder from​(WebhookCreate instance)
        Fill a builder with attribute values from the provided WebhookCreate instance. Regular attribute values will be replaced with those from the given instance. Absent optional values will not replace present values. Collection elements and entries will be added, not replaced.
        Parameters:
        instance - The instance from which to copy values
        Returns:
        this builder for use in a chained invocation
      • name

        @CanIgnoreReturnValue
        public final ImmutableWebhookCreate.Builder name​(@Nullable
                                                         String name)
        Initializes the value for the name attribute.
        Parameters:
        name - The value for name (can be null)
        Returns:
        this builder for use in a chained invocation
      • active

        @CanIgnoreReturnValue
        public final ImmutableWebhookCreate.Builder active​(@Nullable
                                                           Boolean active)
        Initializes the value for the active attribute.
        Parameters:
        active - The value for active (can be null)
        Returns:
        this builder for use in a chained invocation
      • addEvents

        @CanIgnoreReturnValue
        public final ImmutableWebhookCreate.Builder addEvents​(String element)
        Adds one element to events list.
        Parameters:
        element - A events element
        Returns:
        this builder for use in a chained invocation
      • addEvents

        @CanIgnoreReturnValue
        public final ImmutableWebhookCreate.Builder addEvents​(String... elements)
        Adds elements to events list.
        Parameters:
        elements - An array of events elements
        Returns:
        this builder for use in a chained invocation
      • events

        @CanIgnoreReturnValue
        public final ImmutableWebhookCreate.Builder events​(@Nullable
                                                           Iterable<String> elements)
        Sets or replaces all elements for events list.
        Parameters:
        elements - An iterable of events elements
        Returns:
        this builder for use in a chained invocation
      • addAllEvents

        @CanIgnoreReturnValue
        public final ImmutableWebhookCreate.Builder addAllEvents​(Iterable<String> elements)
        Adds elements to events list.
        Parameters:
        elements - An iterable of events elements
        Returns:
        this builder for use in a chained invocation
      • config

        @CanIgnoreReturnValue
        public final ImmutableWebhookCreate.Builder config​(@Nullable
                                                           WebhookConfig config)
        Initializes the value for the config attribute.
        Parameters:
        config - The value for config (can be null)
        Returns:
        this builder for use in a chained invocation