# Class ContactID

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

All Implemented Interfaces:
  `Comparable<ContactID>`

public class ContactID extends Object implements Comparable<ContactID>
Contact ids to facilitate warm starting. Note: the ContactFeatures class is just embedded in here

- ## Nested Class Summary

  Nested Classes
  Modifier and Type
  Class
  Description
  `static enum`
  `ContactID.Type`

- ## Field Summary

  Fields
  Modifier and Type
  Field
  Description
  `byte`
  `indexA`
  `byte`
  `indexB`
  `byte`
  `typeA`
  `byte`
  `typeB`

- ## Constructor Summary

  Constructors
  Constructor
  Description
  `ContactID()`
  `ContactID(ContactID c)`

- ## Method Summary

  Modifier and Type
  Method
  Description
  `int`
  `compareTo(ContactID o)`
  Compares this object to the specified object to determine their relative order.
  `void`
  `flip()`
  `int`
  `getKey()`
  `boolean`
  `isEqual(ContactID cid)`
  `void`
  `set(ContactID c)`
  `void`
  `zero()`
  zeros out the data

  ### Methods inherited from class Object

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

- ## Field Details

  - ### indexA

    public byte indexA

  - ### indexB

    public byte indexB

  - ### typeA

    public byte typeA

  - ### typeB

    public byte typeB

- ## Constructor Details

  - ### ContactID

    public ContactID()

  - ### ContactID

    public ContactID(ContactID c)

- ## Method Details

  - ### getKey

    public int getKey()

  - ### isEqual

    public boolean isEqual(ContactID cid)

  - ### set

    public void set(ContactID c)

  - ### flip

    public void flip()

  - ### zero

    public void zero()
    zeros out the data

  - ### compareTo

    public int compareTo(ContactID o)
    Description copied from interface: `Comparable`

    Compares this object to the specified object to determine their relative order.

    ###### Parameters

    - `another`: the object to compare to this instance.

    ###### Returns

    Specified by:
      `compareTo` in interface `Comparable<ContactID>`
    Returns:

      a negative integer if this instance is less than `another`; a positive integer if this instance is greater than `another`; 0 if this instance has the same order as `another`.

      ###### Throws

      - `ClassCastException`: @throws ClassCastException if `another` cannot be converted into something comparable to `this` instance.