Function License.isValid License isn't available anymore

Hi,
by upgrading to groupdocs-viewer 17.02 we recognized that com.groupdocs.viewer.licensing.License.isValidLicense isn’t available anymore.

King regards, Josef

Hi Josef,


Thanks for sharing your concerns.
We have successfully reproduced same issue at our end using latest version of the API that is 17.2.0. Hence, we’ve logged this scenario in our internal issue tracking system as an investigation. As we get any update from the concerned team, we’ll notify you.

Kind regards
Hi Josef,

In latest version, License.isValidLicense() method has been removed in order to avoid license brute force. As as workaround please check for one of evaluation limitation e.g. Viewer returns only two pages in evaluation mode:

String document = "three-pages.docx";
int expectedPagesCount = 3;       
ViewerHtmlHandler handler = new ViewerHtmlHandler();       
List pages = handler.getPages(document);     
Boolean isLicenseValid = pages.size() == expectedPagesCount;

Also, please find the attached code file, hope it will help.
Best wishes