GroupDocs.Parser for .NET 20.12 Release Notes
This page contains release notes for GroupDocs.Parser for .NET 20.12
Full List of Issues Covering all Changes in this Release
Key | Summary | Category |
---|---|---|
PARSERNET-1690 | Implement the ability to identify whether a file is password-protected | New Feature |
Public API and Backward Incompatible Changes
Description
This feature allows to identify whether a file is password-protected.
Public API changes
The following types were added:
- Added FileInfo class into GroupDocs.Parser.Options namespace.
GroupDocs.Parser.Parser public class was updated with changes as follows:
- Added GetFileInfo(Stream) method
- Added GetFileInfo(String) method
Usage
The following code shows how to check whether a file is password-protected:
// Get a file info
Options.FileInfo info = Parser.GetFileInfo(document);
// Check IsEncrypted property
Console.WriteLine(info.IsEncrypted ? "Password is required" : "");