#

API Docs for: 0.6.0
Show: Inherited Protected Private Deprecated

# Constraint Class

Defined in: `src/constraints/Constraint.js:5`

Constraint base class

## Constructor

### `Constraint`

(

- `bodyA`
- `bodyB`

)

Defined in `src/constraints/Constraint.js:5`

#### Parameters:

- `bodyA` Body
- `bodyB` Body

- Index
- Methods
- Properties

## Item Index

### Methods

- update

### Properties

- bodyA
- bodyB
- collideConnected
- equations
- id

## Methods

### `update`

()

Defined in `src/constraints/Constraint.js:58`

## Properties

### `bodyA`

Body

Defined in `src/constraints/Constraint.js:26`

### `bodyB`

Body

Defined in `src/constraints/Constraint.js:31`

### `collideConnected`

Boolean

Defined in `src/constraints/Constraint.js:41`

Set to true if you want the bodies to collide when they are connected.

### `equations`

Array

Defined in `src/constraints/Constraint.js:19`

Equations to be solved in this constraint

### `id`

Number

Defined in `src/constraints/Constraint.js:36`