예제 #1
0
        private void GetFileStatistics(TestDocument doc, string filePath)
        {
            FileAnalyzer       analyzer = FileAnalyzerFactory.Create(filePath);
            DocumentProperties stats    = analyzer.GetProperties();

            doc.Pages       = stats.Pages;
            doc.Author      = stats.Author;
            doc.Application = stats.Application;
            doc.FileSize    = stats.FileSize;
            doc.Orientation = (stats.Orientation ?? Framework.Documents.Orientation.Portrait).ToString();
        }
예제 #2
0
 /// <summary>
 /// Returns the properties of a document such as page count, title, etc.
 /// </summary>
 /// <returns></returns>
 public DocumentProperties GetProperties() => _analyzer.GetProperties();