Class ImmutableAttributeBuilderDescriptor


  • @ParametersAreNonnullByDefault
    @Generated("org.immutables.processor.ProxyProcessor")
    @Immutable
    public final class ImmutableAttributeBuilderDescriptor
    extends AttributeBuilderDescriptor
    Immutable implementation of AttributeBuilderDescriptor.

    Use the builder to create immutable instances: ImmutableAttributeBuilderDescriptor.builder().

    • Field Detail

      • valueToBuilderMethod

        private final java.lang.String valueToBuilderMethod
      • buildMethod

        private final java.lang.String buildMethod
      • qualifiedValueTypeName

        private final java.lang.String qualifiedValueTypeName
      • qualifiedBuilderTypeName

        private final java.lang.String qualifiedBuilderTypeName
      • qualifiedBuilderConstructorMethod

        private final java.lang.String qualifiedBuilderConstructorMethod
    • Constructor Detail

      • ImmutableAttributeBuilderDescriptor

        private ImmutableAttributeBuilderDescriptor​(AttributeBuilderDescriptor.ValueToBuilderTarget valueToBuilderTarget,
                                                    java.lang.String valueToBuilderMethod,
                                                    java.lang.String buildMethod,
                                                    java.lang.String qualifiedValueTypeName,
                                                    java.lang.String qualifiedBuilderTypeName,
                                                    java.lang.String qualifiedBuilderConstructorMethod)
    • Method Detail

      • getValueToBuilderMethod

        protected java.lang.String getValueToBuilderMethod()
        A method name which when invoked will return a builder with all the properties set from the value object. This method will be invoked based on getValueToBuilderTarget()
        Specified by:
        getValueToBuilderMethod in class AttributeBuilderDescriptor
        Returns:
        method to create a value instance. No () included.
      • getBuildMethod

        public java.lang.String getBuildMethod()
        A method to be invoked on the builder instance which returns a new value instance.
        Specified by:
        getBuildMethod in class AttributeBuilderDescriptor
        Returns:
        a method which constructs a new value instance.
      • getQualifiedBuilderConstructorMethod

        public java.lang.String getQualifiedBuilderConstructorMethod()
        A fully qualified path and method which creates a new instance of a builder. If the builder is constructed from a no-arg constructor, the new keyword should be prepended with a space.
        Specified by:
        getQualifiedBuilderConstructorMethod in class AttributeBuilderDescriptor
        Returns:
        static path which invoked will create a new empty builder. No () included.
      • withValueToBuilderMethod

        public final ImmutableAttributeBuilderDescriptor withValueToBuilderMethod​(java.lang.String value)
        Copy the current immutable object by setting a value for the valueToBuilderMethod attribute. An equals check used to prevent copying of the same value by returning this.
        Parameters:
        value - A new value for valueToBuilderMethod
        Returns:
        A modified copy of the this object
      • withBuildMethod

        public final ImmutableAttributeBuilderDescriptor withBuildMethod​(java.lang.String value)
        Copy the current immutable object by setting a value for the buildMethod attribute. An equals check used to prevent copying of the same value by returning this.
        Parameters:
        value - A new value for buildMethod
        Returns:
        A modified copy of the this object
      • withQualifiedValueTypeName

        public final ImmutableAttributeBuilderDescriptor withQualifiedValueTypeName​(java.lang.String value)
        Copy the current immutable object by setting a value for the qualifiedValueTypeName attribute. An equals check used to prevent copying of the same value by returning this.
        Parameters:
        value - A new value for qualifiedValueTypeName
        Returns:
        A modified copy of the this object
      • withQualifiedBuilderTypeName

        public final ImmutableAttributeBuilderDescriptor withQualifiedBuilderTypeName​(java.lang.String value)
        Copy the current immutable object by setting a value for the qualifiedBuilderTypeName attribute. An equals check used to prevent copying of the same value by returning this.
        Parameters:
        value - A new value for qualifiedBuilderTypeName
        Returns:
        A modified copy of the this object
      • withQualifiedBuilderConstructorMethod

        public final ImmutableAttributeBuilderDescriptor withQualifiedBuilderConstructorMethod​(java.lang.String value)
        Copy the current immutable object by setting a value for the qualifiedBuilderConstructorMethod attribute. An equals check used to prevent copying of the same value by returning this.
        Parameters:
        value - A new value for qualifiedBuilderConstructorMethod
        Returns:
        A modified copy of the this object
      • equals

        public boolean equals​(@Nullable
                              java.lang.Object another)
        This instance is equal to all instances of ImmutableAttributeBuilderDescriptor that have equal attribute values.
        Overrides:
        equals in class java.lang.Object
        Returns:
        true if this is equal to another instance
      • hashCode

        public int hashCode()
        Computes a hash code from attributes: valueToBuilderTarget, valueToBuilderMethod, buildMethod, qualifiedValueTypeName, qualifiedBuilderTypeName, qualifiedBuilderConstructorMethod.
        Overrides:
        hashCode in class java.lang.Object
        Returns:
        hashCode value
      • toString

        public java.lang.String toString()
        Prints the immutable value AttributeBuilderDescriptor with attribute values.
        Overrides:
        toString in class java.lang.Object
        Returns:
        A string representation of the value