Skip to main content

Search OfficeIMO

Enter a topic, API type, or PowerShell command.

Documentation Search all OfficeIMO/
Class

OfficeRasterContentSafety

OfficeIMO.Workflows

Namespace
OfficeIMO.Workflows
Assembly
OfficeIMO.Workflows
Source revision
ba882f6b0d07 with working tree changes
Modifiers
static

OCR-backed concealed-text inspection and explicit rectangular redaction for bounded raster images.

Inheritance

  • object
  • OfficeRasterContentSafety

Methods

InspectAsync 2 overloads
public static async Task<OfficeContentSafetyReport> InspectAsync(byte[] imageBytes, IOcrEngine engine, OfficeRasterContentSafetyOptions? options = null, CancellationToken cancellationToken = default) #

Inspects a single-frame raster image using caller-owned OCR and pixel evidence. Metadata and provider text without bounded geometry never become concealment findings.

Parameters

imageBytes byte[] required
engine OfficeIMO.Ocr.IOcrEngine required
options OfficeIMO.Workflows.OfficeRasterContentSafetyOptions? = null optional
cancellationToken System.Threading.CancellationToken = default optional

Returns

Task<OfficeContentSafetyReport>
public static async Task<OfficeContentSafetyReport> InspectAsync(string filePath, IOcrEngine engine, OfficeRasterContentSafetyOptions? options = null, CancellationToken cancellationToken = default) #

Reads and inspects one bounded raster file.

Parameters

filePath string required
engine OfficeIMO.Ocr.IOcrEngine required
options OfficeIMO.Workflows.OfficeRasterContentSafetyOptions? = null optional
cancellationToken System.Threading.CancellationToken = default optional

Returns

Task<OfficeContentSafetyReport>
public static async Task<OfficeContentCleanupResult> RedactSelectedContentAsync(byte[] imageBytes, IOcrEngine engine, OfficeContentCleanupSelection selection, OfficeRasterContentSafetyOptions options, CancellationToken cancellationToken = default) #

Reinspects an exact raster snapshot, covers only selected cleanup-capable OCR regions with the configured opaque color, emits a single-frame PNG derivative, reopens it, and reruns OCR-backed inspection.

Parameters

imageBytes byte[] required
engine OfficeIMO.Ocr.IOcrEngine required
selection OfficeIMO.ContentSafety.OfficeContentCleanupSelection required
options OfficeIMO.Workflows.OfficeRasterContentSafetyOptions required
cancellationToken System.Threading.CancellationToken = default optional

Returns

Task<OfficeContentCleanupResult>