# SizeRoundingBehavior

Rounding behaviour when converting between units of `Size`.

- Source: [`core/lib/size.ts`](https://github.com/aws/aws-cdk/blob/v2.274.0/packages/aws-cdk-lib/core/lib/size.ts#L221)

## Example

```ts
Size.mebibytes(2).toKibibytes()                                             // yields 2048
Size.kibibytes(2050).toMebibytes({ rounding: SizeRoundingBehavior.FLOOR })  // yields 2
```

## Members

| Member | Description |
| --- | --- |
| `FAIL` | Fail the conversion if the result is not an integer. |
| `FLOOR` | If the result is not an integer, round it to the closest integer less than the result. |
| `NONE` | Don't round. |

## Referenced by

- [`SizeConversionOptions`](/v2/docs/aws-cdk-lib.SizeConversionOptions).rounding
