@Generated(value={"Immutables.generator","Ray2DType"}) public final class Ray2D extends Object implements Ray2DType
| Modifier and Type | Class and Description |
|---|---|
static class |
Ray2D.Builder
Builds instances of type
Ray2D. |
| Modifier and Type | Method and Description |
|---|---|
static Ray2D.Builder |
builder()
Creates a builder for
Ray2D. |
static Ray2D |
copyOf(Ray2DType instance)
Creates an immutable copy of a
Ray2DType value. |
com.io7m.jtensors.core.unparameterized.vectors.Vector2D |
direction() |
com.io7m.jtensors.core.unparameterized.vectors.Vector2D |
directionInverse() |
boolean |
equals(Object another)
This instance is equal to all instances of
Ray2D that have equal attribute values. |
int |
hashCode()
Computes a hash code from attributes:
origin, direction. |
static Ray2D |
of(com.io7m.jtensors.core.unparameterized.vectors.Vector2D origin,
com.io7m.jtensors.core.unparameterized.vectors.Vector2D direction)
Construct a new immutable
Ray2D instance. |
com.io7m.jtensors.core.unparameterized.vectors.Vector2D |
origin() |
String |
toString()
Prints the immutable value
Ray2D with attribute values. |
Ray2D |
withDirection(com.io7m.jtensors.core.unparameterized.vectors.Vector2D value)
Copy the current immutable object by setting a value for the
direction attribute. |
Ray2D |
withOrigin(com.io7m.jtensors.core.unparameterized.vectors.Vector2D value)
Copy the current immutable object by setting a value for the
origin attribute. |
clone, finalize, getClass, notify, notifyAll, wait, wait, waitintersectsAreapublic com.io7m.jtensors.core.unparameterized.vectors.Vector2D origin()
public com.io7m.jtensors.core.unparameterized.vectors.Vector2D direction()
public com.io7m.jtensors.core.unparameterized.vectors.Vector2D directionInverse()
directionInverse in interface Ray2DTypepublic final Ray2D withOrigin(com.io7m.jtensors.core.unparameterized.vectors.Vector2D value)
origin attribute.
A shallow reference equality check is used to prevent copying of the same value by returning this.value - A new value for originthis objectpublic final Ray2D withDirection(com.io7m.jtensors.core.unparameterized.vectors.Vector2D value)
direction attribute.
A shallow reference equality check is used to prevent copying of the same value by returning this.value - A new value for directionthis objectpublic boolean equals(Object another)
Ray2D that have equal attribute values.public int hashCode()
origin, direction.public String toString()
Ray2D with attribute values.public static Ray2D of(com.io7m.jtensors.core.unparameterized.vectors.Vector2D origin, com.io7m.jtensors.core.unparameterized.vectors.Vector2D direction)
Ray2D instance.origin - The value for the origin attributedirection - The value for the direction attributepublic static Ray2D copyOf(Ray2DType instance)
Ray2DType value.
Uses accessors to get values to initialize the new immutable instance.
If an instance is already immutable, it is returned as is.instance - The instance to copypublic static Ray2D.Builder builder()
Ray2D.Copyright © 2017 <code@io7m.com> http://io7m.com