The TimeUnit enum represents different time units for specifying the duration of a project in the GroupDocs.Viewer component. It provides a set of predefined time units that can be used to represent and calculate the duration of a project, such as days, months and so on. For details, see the documentation.
Example usage:
HtmlViewOptions pdfViewOptions = HtmlViewOptions.forEmbeddedResources();
ProjectManagementOptions projectManagementOptions = pdfViewOptions.getProjectManagementOptions();
projectManagementOptions.setTimeUnit(TimeUnit.MONTHS);
try (Viewer viewer = new Viewer("document.mpp")) {
viewer.view(pdfViewOptions);
// Use the viewer object for further operations
}