Module simpa.core

Record Class LocalFrame

java.lang.Object
java.lang.Record
simpa.core.api.utils.LocalFrame

public record LocalFrame(org.apache.commons.math3.geometry.euclidean.threed.Vector3D lx, org.apache.commons.math3.geometry.euclidean.threed.Vector3D ly, org.apache.commons.math3.geometry.euclidean.threed.Vector3D lz) extends Record
Object representing a local coordinate system.
  • Constructor Summary

    Constructors
    Constructor
    Description
    LocalFrame(org.apache.commons.math3.geometry.euclidean.threed.Vector3D lx, org.apache.commons.math3.geometry.euclidean.threed.Vector3D ly, org.apache.commons.math3.geometry.euclidean.threed.Vector3D lz)
    Creates an instance of a LocalFrame record class.
  • Method Summary

    Modifier and Type
    Method
    Description
    final boolean
    Indicates whether some other object is "equal to" this one.
    org.apache.commons.math3.geometry.euclidean.threed.Vector3D
    getLocalShiftedPoint(org.apache.commons.math3.geometry.euclidean.threed.Vector3D basePoint, org.apache.commons.math3.geometry.euclidean.threed.Vector3D shift)
    Get a point near the given base point shifted by the a vector which is rotated to the local frame.
    final int
    Returns a hash code value for this object.
    org.apache.commons.math3.geometry.euclidean.threed.Vector3D
    lx()
    Returns the value of the lx record component.
    org.apache.commons.math3.geometry.euclidean.threed.Vector3D
    ly()
    Returns the value of the ly record component.
    org.apache.commons.math3.geometry.euclidean.threed.Vector3D
    lz()
    Returns the value of the lz record component.
    Returns a string representation of this record class.

    Methods inherited from class java.lang.Object

    getClass, notify, notifyAll, wait, wait, wait
  • Constructor Details

    • LocalFrame

      public LocalFrame(org.apache.commons.math3.geometry.euclidean.threed.Vector3D lx, org.apache.commons.math3.geometry.euclidean.threed.Vector3D ly, org.apache.commons.math3.geometry.euclidean.threed.Vector3D lz)
      Creates an instance of a LocalFrame record class.
      Parameters:
      lx - the value for the lx record component
      ly - the value for the ly record component
      lz - the value for the lz record component
  • Method Details

    • toString

      public String toString()
      Returns a string representation of this record class. The representation contains the name of the class, followed by the name and value of each of the record components.
      Specified by:
      toString in class Record
      Returns:
      a string representation of this object
    • getLocalShiftedPoint

      public org.apache.commons.math3.geometry.euclidean.threed.Vector3D getLocalShiftedPoint(org.apache.commons.math3.geometry.euclidean.threed.Vector3D basePoint, org.apache.commons.math3.geometry.euclidean.threed.Vector3D shift)
      Get a point near the given base point shifted by the a vector which is rotated to the local frame.
      Parameters:
      basePoint - The point to be shifted
      shift - Shift in the local system.
      Returns:
      - A point in the global frame shifted by the given vector in the local frame.
    • hashCode

      public final int hashCode()
      Returns a hash code value for this object. The value is derived from the hash code of each of the record components.
      Specified by:
      hashCode in class Record
      Returns:
      a hash code value for this object
    • equals

      public final boolean equals(Object o)
      Indicates whether some other object is "equal to" this one. The objects are equal if the other object is of the same class and if all the record components are equal. All components in this record class are compared with Objects::equals(Object,Object).
      Specified by:
      equals in class Record
      Parameters:
      o - the object with which to compare
      Returns:
      true if this object is the same as the o argument; false otherwise.
    • lx

      public org.apache.commons.math3.geometry.euclidean.threed.Vector3D lx()
      Returns the value of the lx record component.
      Returns:
      the value of the lx record component
    • ly

      public org.apache.commons.math3.geometry.euclidean.threed.Vector3D ly()
      Returns the value of the ly record component.
      Returns:
      the value of the ly record component
    • lz

      public org.apache.commons.math3.geometry.euclidean.threed.Vector3D lz()
      Returns the value of the lz record component.
      Returns:
      the value of the lz record component