Class Contact2DPtr


  • public class Contact2DPtr
    extends java.lang.Object
    Ptr stores a pointer and optionally takes ownership of the value.
    • Constructor Detail

      • Contact2DPtr

        public Contact2DPtr​(long cPtr,
                            boolean cMemoryOwn)
      • Contact2DPtr

        public Contact2DPtr()
        Default constructor yielding a NULL-pointer.
      • Contact2DPtr

        public Contact2DPtr​(Contact2D ptr)
        Do not take ownership of ptr.

        ptr can be null.

        The constructor is implicit on purpose.
    • Method Detail

      • getCPtr

        public static long getCPtr​(Contact2DPtr obj)
      • delete

        public void delete()
      • deref

        public Contact2D deref()
        The pointer stored in the object.
      • __ref__

        public Contact2D __ref__()
        Dereferencing operator.
      • getDeref

        public Contact2D getDeref()
        Member access operator.
      • equals

        public boolean equals​(Contact2D p)
      • isShared

        public boolean isShared()
        check if this Ptr has shared ownership or none
        ownership
        Returns:
        true if Ptr has shared ownership, false if it has no ownership.
      • isNull

        public boolean isNull()
        checks if the pointer is null
        Returns:
        Returns true if the pointer is null
      • setP

        public void setP​(Vector2D value)
        Contact position
      • getP

        public Vector2D getP()
        Contact position
      • setN

        public void setN​(Vector2D value)
        Surface contact normal
      • getN

        public Vector2D getN()
        Surface contact normal
      • setCurvature

        public void setCurvature​(double value)
        surface curvature
      • getCurvature

        public double getCurvature()
        surface curvature
      • setAvgCurvature

        public void setAvgCurvature​(double value)
        double moving average of the curvature
      • getAvgCurvature

        public double getAvgCurvature()
        double moving average of the curvature
      • setMu

        public void setMu​(double value)
        coulomb friction coefficient
      • getMu

        public double getMu()
        coulomb friction coefficient