# Class AABB

java.lang.Object
com.codename1.gaming.physics.box2d.collision.AABB

public class AABB extends Object

- ## Field Summary

  Fields
  Modifier and Type
  Field
  Description
  `final Vec2`
  `lowerBound`
  `final Vec2`
  `upperBound`

- ## Constructor Summary

  Constructors
  Constructor
  Description
  `AABB()`
  `AABB(AABB copy)`
  `AABB(Vec2 lowerVertex, Vec2 upperVertex)`

- ## Method Summary

  Modifier and Type
  Method
  Description
  `final void`
  `combine(AABB aabb)`
  `final void`
  `combine(AABB aabb1, AABB aab)`
  `final boolean`
  `contains(AABB aabb)`
  `final Vec2`
  `getCenter()`
  `final void`
  `getCenterToOut(Vec2 out)`
  `final Vec2`
  `getExtents()`
  `final void`
  `getExtentsToOut(Vec2 out)`
  `final float`
  `getPerimeter()`
  `final void`
  `getVertices(Vec2[] argRay)`
  `final boolean`
  `isValid()`
  `final boolean`
  `raycast(RayCastOutput output, RayCastInput input)`
  `final boolean`
  `raycast(RayCastOutput output, RayCastInput input, IWorldPool argPool)`
  `final void`
  `set(AABB aabb)`
  `static final boolean`
  `testOverlap(AABB a, AABB b)`
  `final String`
  `toString()`
  Returns a string representation of the object.

  ### Methods inherited from class Object

  `clone, equals, getClass, hashCode, notify, notifyAll, wait, wait, wait`

- ## Field Details

  - ### lowerBound

    public final Vec2 lowerBound

  - ### upperBound

    public final Vec2 upperBound

- ## Constructor Details

  - ### AABB

    public AABB()

  - ### AABB

    public AABB(AABB copy)

  - ### AABB

    public AABB(Vec2 lowerVertex, Vec2 upperVertex)

- ## Method Details

  - ### set

    public final void set(AABB aabb)

  - ### isValid

    public final boolean isValid()

  - ### getCenter

    public final Vec2 getCenter()

  - ### getCenterToOut

    public final void getCenterToOut(Vec2 out)

  - ### getExtents

    public final Vec2 getExtents()

  - ### getExtentsToOut

    public final void getExtentsToOut(Vec2 out)

  - ### getVertices

    public final void getVertices(Vec2[] argRay)

  - ### combine

    public final void combine(AABB aabb1, AABB aab)

  - ### getPerimeter

    public final float getPerimeter()

  - ### combine

    public final void combine(AABB aabb)

  - ### contains

    public final boolean contains(AABB aabb)

  - ### raycast

    public final boolean raycast(RayCastOutput output, RayCastInput input)

  - ### raycast

    public final boolean raycast(RayCastOutput output, RayCastInput input, IWorldPool argPool)

  - ### testOverlap

    public static final boolean testOverlap(AABB a, AABB b)

  - ### toString

    public final String toString()
    Description copied from class: `Object`
    Returns a string representation of the object. In general, the toString method returns a string that "textually represents" this object. The result should be a concise but informative representation that is easy for a person to read. It is recommended that all subclasses override this method. The toString method for class Object returns a string consisting of the name of the class of which the object is an instance, the at-sign character `@', and the unsigned hexadecimal representation of the hash code of the object. In other words, this method returns a string equal to the value of: getClass().getName() + '@' + Integer.toHexString(hashCode())
    Overrides:
      `toString` in class `Object`