---
title: "ImageQualityViolation | Customer's Canvas On-Premises"
canonical: "https://customerscanvas.com/docs/on-premises/design-atoms-js/reference/design-atoms/ImageQualityViolation/"
---

# ImageQualityViolation

> - [`Violation`](https://customerscanvas.com/docs/on-premises/design-atoms-js/reference/design-atoms/Violation.md#abstract-violation)

## Classes

### ImageQualityViolation

#### Extends

#### Constructors

##### Constructor

```ts
new ImageQualityViolation(
   productHandler, 
   config, 
   messages, 
   renderingDpi, 
   eventManager): ImageQualityViolation;
```

###### Parameters

| Parameter | Type |
| ------ | ------ |
| `productHandler` | [`ProductHandler`](https://customerscanvas.com/docs/on-premises/design-atoms-js/reference/design-atoms/ProductHandler.md#producthandler) |
| `config` | [`IQualityMeterConfig`](https://customerscanvas.com/docs/on-premises/design-atoms-js/reference/design-atoms/IViolationServiceConfiguration.md#iqualitymeterconfig) |
| `messages` | [`IViewerMessagesConfig`](https://customerscanvas.com/docs/on-premises/design-atoms-js/reference/design-atoms/IViewerMessagesConfig.md#iviewermessagesconfig) |
| `renderingDpi` | `number` |
| `eventManager` | [`EventManager`](https://customerscanvas.com/docs/on-premises/design-atoms-js/reference/design-atoms/EventManager.md#eventmanager) |

###### Returns

[`ImageQualityViolation`](#imagequalityviolation)

###### Overrides

[`Violation`](https://customerscanvas.com/docs/on-premises/design-atoms-js/reference/design-atoms/Violation.md#abstract-violation).[`constructor`](https://customerscanvas.com/docs/on-premises/design-atoms-js/reference/design-atoms/Violation.md#constructor)

#### Properties

##### prepareItem

```ts
prepareItem: (item) => void;
```

###### Parameters

| Parameter | Type |
| ------ | ------ |
| `item` | `Item` |

###### Returns

`void`

###### Inherited from

[`Violation`](https://customerscanvas.com/docs/on-premises/design-atoms-js/reference/design-atoms/Violation.md#abstract-violation).[`prepareItem`](https://customerscanvas.com/docs/on-premises/design-atoms-js/reference/design-atoms/Violation.md#prepareitem)

##### dataPropertyName

```ts
static dataPropertyName: string = "qualityViolationData";
```

##### statePropertyName

```ts
static statePropertyName: string = "qualityViolationState";
```

#### Accessors

##### renderingDpi

###### Set Signature

```ts
set renderingDpi(value): void;
```

###### Parameters

| Parameter | Type |
| ------ | ------ |
| `value` | `number` |

###### Returns

`void`

#### Methods

##### getDataPropertyName()

```ts
getDataPropertyName(): string;
```

###### Returns

`string`

###### Overrides

[`Violation`](https://customerscanvas.com/docs/on-premises/design-atoms-js/reference/design-atoms/Violation.md#abstract-violation).[`getDataPropertyName`](https://customerscanvas.com/docs/on-premises/design-atoms-js/reference/design-atoms/Violation.md#getdatapropertyname)

##### getStatePropertyName()

```ts
getStatePropertyName(): string;
```

###### Returns

`string`

###### Overrides

[`Violation`](https://customerscanvas.com/docs/on-premises/design-atoms-js/reference/design-atoms/Violation.md#abstract-violation).[`getStatePropertyName`](https://customerscanvas.com/docs/on-premises/design-atoms-js/reference/design-atoms/Violation.md#getstatepropertyname)

##### getViolationInfo()

```ts
getViolationInfo(item, oldViolationInfo): IViolationInfo;
```

###### Parameters

| Parameter | Type |
| ------ | ------ |
| `item` | `Item` |
| `oldViolationInfo` | [`ITotalViolationInfo`](https://customerscanvas.com/docs/on-premises/design-atoms-js/reference/design-atoms/Violation.md#itotalviolationinfo) |

###### Returns

[`IViolationInfo`](https://customerscanvas.com/docs/on-premises/design-atoms-js/reference/design-atoms/Violation.md#iviolationinfo)

###### Overrides

[`Violation`](https://customerscanvas.com/docs/on-premises/design-atoms-js/reference/design-atoms/Violation.md#abstract-violation).[`getViolationInfo`](https://customerscanvas.com/docs/on-premises/design-atoms-js/reference/design-atoms/Violation.md#getviolationinfo)

##### isAvailableFor()

```ts
isAvailableFor(item): boolean;
```

###### Parameters

| Parameter | Type |
| ------ | ------ |
| `item` | `Item` |

###### Returns

`boolean`

###### Overrides

[`Violation`](https://customerscanvas.com/docs/on-premises/design-atoms-js/reference/design-atoms/Violation.md#abstract-violation).[`isAvailableFor`](https://customerscanvas.com/docs/on-premises/design-atoms-js/reference/design-atoms/Violation.md#isavailablefor)

##### computeTotalViolationInfo()

```ts
static computeTotalViolationInfo(
   violations, 
   item, 
   oldViolationInfo): ITotalViolationInfo;
```

###### Parameters

| Parameter | Type |
| ------ | ------ |
| `violations` | [`Violation`](https://customerscanvas.com/docs/on-premises/design-atoms-js/reference/design-atoms/Violation.md#abstract-violation)[] |
| `item` | `Item` |
| `oldViolationInfo` | [`ITotalViolationInfo`](https://customerscanvas.com/docs/on-premises/design-atoms-js/reference/design-atoms/Violation.md#itotalviolationinfo) |

###### Returns

[`ITotalViolationInfo`](https://customerscanvas.com/docs/on-premises/design-atoms-js/reference/design-atoms/Violation.md#itotalviolationinfo)

###### Inherited from

[`Violation`](https://customerscanvas.com/docs/on-premises/design-atoms-js/reference/design-atoms/Violation.md#abstract-violation).[`computeTotalViolationInfo`](https://customerscanvas.com/docs/on-premises/design-atoms-js/reference/design-atoms/Violation.md#computetotalviolationinfo)

## Interfaces

### IDpiChangedEventArgs

#### Properties

##### item

```ts
item: Item;
```

##### newValue

```ts
newValue: number;
```

##### oldValue

```ts
oldValue: number;
```

##### state

```ts
state: ViolationState;
```

***

### IImageQualityViolationData

#### Properties

##### dpiValue

```ts
dpiValue: number;
```
