Class ImmutableTrees.Invoke

    • Method Detail

      • withAccess

        public final ImmutableTrees.Invoke withAccess​(Trees.AccessExpression value)
        Copy the current immutable object by setting a value for the access attribute. A shallow reference equality check is used to prevent copying of the same value by returning this.
        Parameters:
        value - A new value for access
        Returns:
        A modified copy of the this object
      • withInvoke

        public final ImmutableTrees.Invoke withInvoke​(Trees.ApplyExpression value)
        Copy the current immutable object by setting a present value for the optional invoke attribute.
        Parameters:
        value - The value for invoke
        Returns:
        A modified copy of this object
      • withInvoke

        public final ImmutableTrees.Invoke withInvoke​(com.google.common.base.Optional<? extends Trees.ApplyExpression> optional)
        Copy the current immutable object by setting an optional value for the invoke attribute. A shallow reference equality check on the optional value is used to prevent copying of the same value by returning this.
        Parameters:
        optional - A value for invoke
        Returns:
        A modified copy of this object
      • equals

        public boolean equals​(@Nullable
                              java.lang.Object another)
        This instance is equal to all instances of Invoke 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: access, invoke.
        Overrides:
        hashCode in class java.lang.Object
        Returns:
        hashCode value
      • toString

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

        public static ImmutableTrees.Invoke copyOf​(Trees.Invoke instance)
        Creates an immutable copy of a Trees.Invoke value. Uses accessors to get values to initialize the new immutable instance. If an instance is already immutable, it is returned as is.
        Parameters:
        instance - The instance to copy
        Returns:
        A copied immutable Invoke instance
      • builder

        public static ImmutableTrees.Invoke.Builder builder()
        Creates a builder for Invoke.
         ImmutableTrees.Invoke.builder()
            .access(org.immutables.generator.processor.Trees.AccessExpression) // required access
            .invoke(org.immutables.generator.processor.Trees.ApplyExpression) // optional invoke
            .build();
         
        Returns:
        A new Invoke builder