# OfficeDiffOptions

Settings for OfficeDiff. Review signatures, members, parameters, type relationships, and available reference details in OfficeIMO.Core API Reference.

Class 

`OfficeIMO.Diff`

**Namespace**

`OfficeIMO.Diff`

**Assembly**

`OfficeIMO.Core`

**Source revision**

`ba882f6b0d07` with working tree changes

**Source**

[OfficeDiffTypes.cs:99](https://github.com/EvotecIT/OfficeIMO/blob/ba882f6b0d07acddd884b5e7d3086b0cfff0a05a/OfficeIMO.Core/Diff/OfficeDiffTypes.cs#L99)

**Modifiers**

sealed

Settings for [OfficeDiff](/api/core/officeimo-diff-officediff/).

## Inheritance

- object
- OfficeDiffOptions

## Usage

Explore 7 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 [OfficeDiffHtmlOptions.DiffOptions](/api/core/officeimo-diff-officediffhtmloptions/#property-diffoptions)

### Accepted by parameters 6

- Method [OfficeDiff.CompareCharacters](/api/core/officeimo-diff-officediff/#method-comparecharacters-string-string-officeimo-diff-officediffoptions-threading-cancellationtoken) parameter `options`
- Method [OfficeDiff.CompareLines](/api/core/officeimo-diff-officediff/#method-comparelines-string-string-officeimo-diff-officediffoptions-threading-cancellationtoken) parameter `options`
- Method [OfficeDiff.CompareTokens](/api/core/officeimo-diff-officediff/#method-comparetokens-collections-generic-ireadonlylist-officeimo-diff-officetexttoken-collections-generic-ireadonlylist-officeimo-diff-officetexttoken-officeimo-diff-officediffoptions-threading-cancellationtoken) parameter `options`
- Method [OfficeDiff.CompareWords](/api/core/officeimo-diff-officediff/#method-comparewords-string-string-officeimo-diff-officediffoptions-threading-cancellationtoken) parameter `options`
- Method [OfficeDiff.Compare``1](/api/core/officeimo-diff-officediff/#method-compare-collections-generic-ireadonlylist-collections-generic-ireadonlylist-collections-generic-iequalitycomparer-officeimo-diff-officediffoptions-threading-cancellationtoken) parameter `options`
- Method [OfficeUnifiedDiff.Create](/api/core/officeimo-diff-officeunifieddiff/#method-create-string-string-string-string-int32-officeimo-diff-officediffoptions-threading-cancellationtoken) parameter `options`

Filter members 

Show inherited

## Constructors

`public OfficeDiffOptions()` [#](#constructor-ctor)

[OfficeDiffTypes.cs:99](https://github.com/EvotecIT/OfficeIMO/blob/ba882f6b0d07acddd884b5e7d3086b0cfff0a05a/OfficeIMO.Core/Diff/OfficeDiffTypes.cs#L99)

## 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 OfficeDiffAlgorithm Algorithm { get; set; }` [#](#property-algorithm)

[OfficeDiffTypes.cs:86](https://github.com/EvotecIT/OfficeIMO/blob/ba882f6b0d07acddd884b5e7d3086b0cfff0a05a/OfficeIMO.Core/Diff/OfficeDiffTypes.cs#L86)

Alignment strategy. The default is [OfficeDiffAlgorithm.Myers](/api/core/officeimo-diff-officediffalgorithm/).

`public bool SemanticCleanup { get; set; }` [#](#property-semanticcleanup)

[OfficeDiffTypes.cs:93](https://github.com/EvotecIT/OfficeIMO/blob/ba882f6b0d07acddd884b5e7d3086b0cfff0a05a/OfficeIMO.Core/Diff/OfficeDiffTypes.cs#L93)

Merges short equal runs that sit between changes into the surrounding change, so that a change reads as one replacement instead of alternating fragments. The weight of a run is its item count, or its character count for text tokens. The default is false.

`public long MaxWorkUnits { get; set; }` [#](#property-maxworkunits)

[OfficeDiffTypes.cs:99](https://github.com/EvotecIT/OfficeIMO/blob/ba882f6b0d07acddd884b5e7d3086b0cfff0a05a/OfficeIMO.Core/Diff/OfficeDiffTypes.cs#L99)

Maximum number of comparison steps before the remaining regions are reported as whole deletions and insertions. Zero or less means no limit. The default is 50,000,000.

`public TimeSpan? Timeout { get; set; }` [#](#property-timeout)

[OfficeDiffTypes.cs:102](https://github.com/EvotecIT/OfficeIMO/blob/ba882f6b0d07acddd884b5e7d3086b0cfff0a05a/OfficeIMO.Core/Diff/OfficeDiffTypes.cs#L102)

Maximum time spent aligning before the remaining regions are reported as whole deletions and insertions. Null or Timeout.InfiniteTimeSpan means no limit.

`public bool IgnoreCase { get; set; }` [#](#property-ignorecase)

[OfficeDiffTypes.cs:105](https://github.com/EvotecIT/OfficeIMO/blob/ba882f6b0d07acddd884b5e7d3086b0cfff0a05a/OfficeIMO.Core/Diff/OfficeDiffTypes.cs#L105)

Text comparison ignores case when true. Applies to the text helpers only.

`public bool IgnoreWhitespace { get; set; }` [#](#property-ignorewhitespace)

[OfficeDiffTypes.cs:111](https://github.com/EvotecIT/OfficeIMO/blob/ba882f6b0d07acddd884b5e7d3086b0cfff0a05a/OfficeIMO.Core/Diff/OfficeDiffTypes.cs#L111)

Text comparison treats every whitespace token as equal to any other whitespace token when true, so changes in spacing or line breaks between words are not reported. Applies to the word and line helpers only.

<!-- PowerForge markdown artifact sha256:BB8D7961E71D01CE298C80B0111E44BCA5523FC2F2A2AF73C66EA44B22EF6A02 -->
