Class ImmutableInitSession.Builder

  • Enclosing class:
    ImmutableInitSession

    @NotThreadSafe
    public static final class ImmutableInitSession.Builder
    extends Object
    Builds instances of type ImmutableInitSession. 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 ImmutableInitSession.Builder from​(DialobComposerServiceController.InitSession instance)
        Fill a builder with attribute values from the provided InitSession 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
      • formId

        @CanIgnoreReturnValue
        public final ImmutableInitSession.Builder formId​(String formId)
        Initializes the value for the formId attribute.
        Parameters:
        formId - The value for formId
        Returns:
        this builder for use in a chained invocation
      • language

        @CanIgnoreReturnValue
        public final ImmutableInitSession.Builder language​(String language)
        Initializes the value for the language attribute.
        Parameters:
        language - The value for language
        Returns:
        this builder for use in a chained invocation
      • putContextValues

        @CanIgnoreReturnValue
        public final ImmutableInitSession.Builder putContextValues​(String key,
                                                                   Object value)
        Put one entry to the contextValues map.
        Parameters:
        key - The key in the contextValues map
        value - The associated value in the contextValues map
        Returns:
        this builder for use in a chained invocation
      • putContextValues

        @CanIgnoreReturnValue
        public final ImmutableInitSession.Builder putContextValues​(Map.Entry<String,​? extends Object> entry)
        Put one entry to the contextValues map. Nulls are not permitted
        Parameters:
        entry - The key and value entry
        Returns:
        this builder for use in a chained invocation
      • contextValues

        @CanIgnoreReturnValue
        public final ImmutableInitSession.Builder contextValues​(Map<String,​? extends Object> entries)
        Sets or replaces all mappings from the specified map as entries for the contextValues map. Nulls are not permitted
        Parameters:
        entries - The entries that will be added to the contextValues map
        Returns:
        this builder for use in a chained invocation
      • putAllContextValues

        @CanIgnoreReturnValue
        public final ImmutableInitSession.Builder putAllContextValues​(Map<String,​? extends Object> entries)
        Put all mappings from the specified map as entries to contextValues map. Nulls are not permitted
        Parameters:
        entries - The entries that will be added to the contextValues map
        Returns:
        this builder for use in a chained invocation