Class
OfficeRasterContentSafety
OfficeIMO.Workflows
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[]
- engine OfficeIMO.Ocr.IOcrEngine
- options OfficeIMO.Workflows.OfficeRasterContentSafetyOptions? = null
- cancellationToken System.Threading.CancellationToken = default
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
- engine OfficeIMO.Ocr.IOcrEngine
- options OfficeIMO.Workflows.OfficeRasterContentSafetyOptions? = null
- cancellationToken System.Threading.CancellationToken = default
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[]
- engine OfficeIMO.Ocr.IOcrEngine
- selection OfficeIMO.ContentSafety.OfficeContentCleanupSelection
- options OfficeIMO.Workflows.OfficeRasterContentSafetyOptions
- cancellationToken System.Threading.CancellationToken = default
Returns
Task<OfficeContentCleanupResult>