# EmailStorePstCompactionOptions

Selection, estimation, fidelity, and verification policy for a safe PST rewrite compaction.

Class 

`OfficeIMO.Email.Store`

**Namespace**

`OfficeIMO.Email.Store`

**Assembly**

`OfficeIMO.Email`

**Source revision**

`be6c300e4ab1` with working tree changes

**Source**

[EmailStorePstCompactionOptions.cs:8](https://github.com/EvotecIT/OfficeIMO/blob/be6c300e4ab1859837b961c64fbfb2b2a1886cd0/Sources/OfficeIMO.Email/Store/Maintenance/EmailStorePstCompactionOptions.cs#L8)

**Modifiers**

sealed

Selection, estimation, fidelity, and verification policy for a safe PST rewrite compaction.

## Inheritance

- object
- EmailStorePstCompactionOptions

## Usage

Explore 3 API references to this type

This type appears in these public API surfaces even when no hand-authored example is attached directly to the page.

### Returned or exposed by 1

- Property [EmailStorePstCompactionPlan.Options](/api/email/officeimo-email-store-emailstorepstcompactionplan/#property-options)

### Accepted by parameters 2

- Method [EmailStoreSession.CompactToPst](/api/email/officeimo-email-store-emailstoresession/#method-compacttopst-string-officeimo-email-store-emailstorepstcompactionoptions-threading-cancellationtoken) parameter `options`
- Method [EmailStoreSession.PlanPstCompaction](/api/email/officeimo-email-store-emailstoresession/#method-planpstcompaction-string-officeimo-email-store-emailstorepstcompactionoptions-threading-cancellationtoken) parameter `options`

Filter members 

Show inherited

## Constructors

`public EmailStorePstCompactionOptions(bool overwriteExisting = false, bool failOnLoss = true, bool continueOnItemError = false, bool includeAssociatedItems = true, bool includeOrphanedItems = true, bool includeSearchFolders = false, int maxItems = 1000000, int maxNestedMessageDepth = 32, long unknownItemEstimateBytes = 1048576, long perItemOverheadBytes = 16384, long fixedPstOverheadBytes = 1048576, string? displayName = null, EmailSemanticComparisonOptions? verificationOptions = null, int maxVerificationIssues = 1000)` [#](#constructor-ctor-boolean-boolean-boolean-boolean-boolean-boolean-int32-int32-int64-int64-int64-string-officeimo-email-emailsemanticcomparisonoptions-int32)

[EmailStorePstCompactionOptions.cs:8](https://github.com/EvotecIT/OfficeIMO/blob/be6c300e4ab1859837b961c64fbfb2b2a1886cd0/Sources/OfficeIMO.Email/Store/Maintenance/EmailStorePstCompactionOptions.cs#L8)

Creates compaction options.

Parameters

**overwriteExisting bool = false optional**

**failOnLoss bool = true optional**

**continueOnItemError bool = false optional**

**includeAssociatedItems bool = true optional**

**includeOrphanedItems bool = true optional**

**includeSearchFolders bool = false optional**

**maxItems int = 1000000 optional**

**maxNestedMessageDepth int = 32 optional**

**unknownItemEstimateBytes long = 1048576 optional**

**perItemOverheadBytes long = 16384 optional**

**fixedPstOverheadBytes long = 1048576 optional**

**displayName string? = null optional**

**verificationOptions OfficeIMO.Email.EmailSemanticComparisonOptions? = null optional**

**maxVerificationIssues int = 1000 optional**

## Inherited Methods

`public virtual bool Equals(object? obj)` [#](#method-equals-object)

Inherited from object

Parameters

**obj object? required**

Returns

`bool`

`public virtual int GetHashCode()` [#](#method-gethashcode)

Inherited from object

Returns

`int`

`public Type GetType()` [#](#method-gettype)

Inherited from object

Returns

`Type`

`public virtual string? ToString()` [#](#method-tostring)

Inherited from object

Returns

`string?`

## Properties

`public bool OverwriteExisting { get; }` [#](#property-overwriteexisting)

[EmailStorePstCompactionOptions.cs:46](https://github.com/EvotecIT/OfficeIMO/blob/be6c300e4ab1859837b961c64fbfb2b2a1886cd0/Sources/OfficeIMO.Email/Store/Maintenance/EmailStorePstCompactionOptions.cs#L46)

Whether an existing distinct destination may be atomically replaced after verification.

`public bool FailOnLoss { get; }` [#](#property-failonloss)

[EmailStorePstCompactionOptions.cs:48](https://github.com/EvotecIT/OfficeIMO/blob/be6c300e4ab1859837b961c64fbfb2b2a1886cd0/Sources/OfficeIMO.Email/Store/Maintenance/EmailStorePstCompactionOptions.cs#L48)

Whether any fidelity warning/error blocks destination commit.

`public bool ContinueOnItemError { get; }` [#](#property-continueonitemerror)

[EmailStorePstCompactionOptions.cs:50](https://github.com/EvotecIT/OfficeIMO/blob/be6c300e4ab1859837b961c64fbfb2b2a1886cd0/Sources/OfficeIMO.Email/Store/Maintenance/EmailStorePstCompactionOptions.cs#L50)

Whether an unreadable item is reported and skipped.

`public bool IncludeAssociatedItems { get; }` [#](#property-includeassociateditems)

[EmailStorePstCompactionOptions.cs:52](https://github.com/EvotecIT/OfficeIMO/blob/be6c300e4ab1859837b961c64fbfb2b2a1886cd0/Sources/OfficeIMO.Email/Store/Maintenance/EmailStorePstCompactionOptions.cs#L52)

Whether folder-associated information items are retained.

`public bool IncludeOrphanedItems { get; }` [#](#property-includeorphaneditems)

[EmailStorePstCompactionOptions.cs:54](https://github.com/EvotecIT/OfficeIMO/blob/be6c300e4ab1859837b961c64fbfb2b2a1886cd0/Sources/OfficeIMO.Email/Store/Maintenance/EmailStorePstCompactionOptions.cs#L54)

Whether readable source-index orphans are recovered into the compacted output.

`public bool IncludeSearchFolders { get; }` [#](#property-includesearchfolders)

[EmailStorePstCompactionOptions.cs:56](https://github.com/EvotecIT/OfficeIMO/blob/be6c300e4ab1859837b961c64fbfb2b2a1886cd0/Sources/OfficeIMO.Email/Store/Maintenance/EmailStorePstCompactionOptions.cs#L56)

Whether search folders are retained as static folders.

`public int MaxItems { get; }` [#](#property-maxitems)

[EmailStorePstCompactionOptions.cs:58](https://github.com/EvotecIT/OfficeIMO/blob/be6c300e4ab1859837b961c64fbfb2b2a1886cd0/Sources/OfficeIMO.Email/Store/Maintenance/EmailStorePstCompactionOptions.cs#L58)

Maximum source references scanned and written.

`public int MaxNestedMessageDepth { get; }` [#](#property-maxnestedmessagedepth)

[EmailStorePstCompactionOptions.cs:60](https://github.com/EvotecIT/OfficeIMO/blob/be6c300e4ab1859837b961c64fbfb2b2a1886cd0/Sources/OfficeIMO.Email/Store/Maintenance/EmailStorePstCompactionOptions.cs#L60)

Maximum embedded-item depth read and written.

`public long UnknownItemEstimateBytes { get; }` [#](#property-unknownitemestimatebytes)

[EmailStorePstCompactionOptions.cs:62](https://github.com/EvotecIT/OfficeIMO/blob/be6c300e4ab1859837b961c64fbfb2b2a1886cd0/Sources/OfficeIMO.Email/Store/Maintenance/EmailStorePstCompactionOptions.cs#L62)

Planning estimate for items without a declared source size.

`public long PerItemOverheadBytes { get; }` [#](#property-peritemoverheadbytes)

[EmailStorePstCompactionOptions.cs:64](https://github.com/EvotecIT/OfficeIMO/blob/be6c300e4ab1859837b961c64fbfb2b2a1886cd0/Sources/OfficeIMO.Email/Store/Maintenance/EmailStorePstCompactionOptions.cs#L64)

Planning estimate for per-item PST rows, nodes, and indexes.

`public long FixedPstOverheadBytes { get; }` [#](#property-fixedpstoverheadbytes)

[EmailStorePstCompactionOptions.cs:66](https://github.com/EvotecIT/OfficeIMO/blob/be6c300e4ab1859837b961c64fbfb2b2a1886cd0/Sources/OfficeIMO.Email/Store/Maintenance/EmailStorePstCompactionOptions.cs#L66)

Planning estimate for fixed PST structures and allocation maps.

`public string? DisplayName { get; }` [#](#property-displayname)

[EmailStorePstCompactionOptions.cs:68](https://github.com/EvotecIT/OfficeIMO/blob/be6c300e4ab1859837b961c64fbfb2b2a1886cd0/Sources/OfficeIMO.Email/Store/Maintenance/EmailStorePstCompactionOptions.cs#L68)

Optional destination display name.

`public EmailSemanticComparisonOptions? VerificationOptions { get; }` [#](#property-verificationoptions)

[EmailStorePstCompactionOptions.cs:70](https://github.com/EvotecIT/OfficeIMO/blob/be6c300e4ab1859837b961c64fbfb2b2a1886cd0/Sources/OfficeIMO.Email/Store/Maintenance/EmailStorePstCompactionOptions.cs#L70)

Optional semantic verification policy.

`public int MaxVerificationIssues { get; }` [#](#property-maxverificationissues)

[EmailStorePstCompactionOptions.cs:72](https://github.com/EvotecIT/OfficeIMO/blob/be6c300e4ab1859837b961c64fbfb2b2a1886cd0/Sources/OfficeIMO.Email/Store/Maintenance/EmailStorePstCompactionOptions.cs#L72)

Maximum mismatch/failure details retained.

<!-- PowerForge markdown artifact sha256:34BF36E4A24072CA8CE23E818DFF0E2624EE6CE429175BC179029935C2BA4B17 -->
