Module org.dyn4j

Class AbstractCollisionPair<T>

    • Constructor Detail

      • AbstractCollisionPair

        public AbstractCollisionPair()
    • Method Detail

      • getHashCode

        public static int getHashCode​(CollisionBody<?> body1,
                                      Fixture fixture1,
                                      CollisionBody<?> body2,
                                      Fixture fixture2)
        Returns the hashcode for a collision pair.
        Parameters:
        body1 - the first body
        fixture1 - the first body's fixture
        body2 - the second body
        fixture2 - the second body's fixture
        Returns:
        int
      • getHashCode

        public static int getHashCode​(Object item1,
                                      Object item2)
        Returns the hashcode for a pair of objects assuming order doesn't matter.
        Parameters:
        item1 - the first object
        item2 - the second object
        Returns:
        int
        Since:
        4.1.0
      • equals

        public static boolean equals​(CollisionPair<?> pairA,
                                     Object obj)
        Returns true if the given pair and object are equal.
        Parameters:
        pairA - the first pair
        obj - the other object
        Returns:
        boolean