Class ImmutableStandardReferenceFrame


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

    Use the builder to create immutable instances: ImmutableStandardReferenceFrame.builder(). Use the static factory method to create immutable instances: ImmutableStandardReferenceFrame.of().

    • Method Detail

      • origin

        public org.apache.commons.math3.geometry.euclidean.threed.Vector3D origin()
        Specified by:
        origin in class StandardReferenceFrame
        Returns:
        The value of the origin attribute
      • x

        public org.apache.commons.math3.geometry.euclidean.threed.Vector3D x()
        Specified by:
        x in class StandardReferenceFrame
        Returns:
        The value of the x attribute
      • y

        public org.apache.commons.math3.geometry.euclidean.threed.Vector3D y()
        Specified by:
        y in class StandardReferenceFrame
        Returns:
        The value of the y attribute
      • z

        public org.apache.commons.math3.geometry.euclidean.threed.Vector3D z()
        Specified by:
        z in class StandardReferenceFrame
        Returns:
        The value of the z attribute
      • withOrigin

        public final ImmutableStandardReferenceFrame withOrigin​(org.apache.commons.math3.geometry.euclidean.threed.Vector3D value)
        Copy the current immutable object by setting a value for the origin attribute. A shallow reference equality check is used to prevent copying of the same value by returning this.
        Parameters:
        value - A new value for origin
        Returns:
        A modified copy of the this object
      • withX

        public final ImmutableStandardReferenceFrame withX​(org.apache.commons.math3.geometry.euclidean.threed.Vector3D value)
        Copy the current immutable object by setting a value for the x attribute. A shallow reference equality check is used to prevent copying of the same value by returning this.
        Parameters:
        value - A new value for x
        Returns:
        A modified copy of the this object
      • withY

        public final ImmutableStandardReferenceFrame withY​(org.apache.commons.math3.geometry.euclidean.threed.Vector3D value)
        Copy the current immutable object by setting a value for the y attribute. A shallow reference equality check is used to prevent copying of the same value by returning this.
        Parameters:
        value - A new value for y
        Returns:
        A modified copy of the this object
      • withZ

        public final ImmutableStandardReferenceFrame withZ​(org.apache.commons.math3.geometry.euclidean.threed.Vector3D value)
        Copy the current immutable object by setting a value for the z attribute. A shallow reference equality check is used to prevent copying of the same value by returning this.
        Parameters:
        value - A new value for z
        Returns:
        A modified copy of the this object
      • withLongAxisAtom

        public final ImmutableStandardReferenceFrame withLongAxisAtom​(Optional<PdbAtomLine> value)
        Copy the current immutable object by setting a value for the longAxisAtom attribute. An equals check used to prevent copying of the same value by returning this.
        Parameters:
        value - A new value for longAxisAtom
        Returns:
        A modified copy of the this object
      • equals

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

        public int hashCode()
        Computes a hash code from attributes: origin, x, y, z, longAxisAtom.
        Overrides:
        hashCode in class Object
        Returns:
        hashCode value
      • toString

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

        public static ImmutableStandardReferenceFrame of​(org.apache.commons.math3.geometry.euclidean.threed.Vector3D origin,
                                                         org.apache.commons.math3.geometry.euclidean.threed.Vector3D x,
                                                         org.apache.commons.math3.geometry.euclidean.threed.Vector3D y,
                                                         org.apache.commons.math3.geometry.euclidean.threed.Vector3D z)
        Construct a new immutable StandardReferenceFrame instance.
        Parameters:
        origin - The value for the origin attribute
        x - The value for the x attribute
        y - The value for the y attribute
        z - The value for the z attribute
        Returns:
        An immutable StandardReferenceFrame instance
      • copyOf

        public static ImmutableStandardReferenceFrame copyOf​(StandardReferenceFrame instance)
        Creates an immutable copy of a StandardReferenceFrame 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 StandardReferenceFrame instance
      • builder

        public static ImmutableStandardReferenceFrame.Builder builder()
        Creates a builder for ImmutableStandardReferenceFrame.
         ImmutableStandardReferenceFrame.builder()
            .origin(org.apache.commons.math3.geometry.euclidean.threed.Vector3D) // required origin
            .x(org.apache.commons.math3.geometry.euclidean.threed.Vector3D) // required x
            .y(org.apache.commons.math3.geometry.euclidean.threed.Vector3D) // required y
            .z(org.apache.commons.math3.geometry.euclidean.threed.Vector3D) // required z
            .longAxisAtom(Optional&lt;pl.poznan.put.pdb.PdbAtomLine&gt;) // optional longAxisAtom
            .build();
         
        Returns:
        A new ImmutableStandardReferenceFrame builder