# PartitionModes

Parameter `PartitionModes` is used to select the mode used to apply partition process when decoding QRCode and DataMatrix.

## JSON Structure

**Location in template:**
```
BarcodeFormatSpecificationOptions[i]
    └── PartitionModes
```

**Parent object:** [BarcodeFormatSpecification](https://www.dynamsoft.com/capture-vision/docs/core/parameters/reference/barcode-format-specification/index.md) object

**Example:**

```json
{
    "PartitionModes": ["PM_WHOLE_BARCODE"]
}
```

> [!NOTE]
> - This snippet shows only the `PartitionModes` parameter.
> - To use it, embed this parameter within a [BarcodeFormatSpecification](https://www.dynamsoft.com/capture-vision/docs/core/parameters/reference/barcode-format-specification/index.md) object.
> - For the complete JSON structure, see:
>   - [Full JSON Structure](https://www.dynamsoft.com/capture-vision/docs/core/parameters/reference/index.md#full-json-structure)
>   - [Minimal Valid JSON](https://www.dynamsoft.com/capture-vision/docs/core/parameters/reference/index.md#minimal-valid-json-example)

## Parameter Details

The structure of the `PartitionModes` is shown as follow:

| PartitionModes  Parameter Details |
| :--------------------------------- |
| **Type**<br>*string array* |
| **Candidate Mode List**<br>PM_WHOLE_BARCODE<br>PM_ALIGNMENT_PARTITION |
| **Default Value**<br> ["PM_WHOLE_BARCODE","PM_ALIGNMENT_PARTITION"] |

## Candidate Mode introduction

### PM_WHOLE_BARCODE

Take the whole barcode for decoding.

### PM_ALIGNMENT_PARTITION

Partition the barcode to blocks based on alignment.
