public class MSOUtils extends Object
| Constructor and Description | 
|---|
| MSOUtils() | 
| Modifier and Type | Method and Description | 
|---|---|
| static void | fillTemplate(InputStream input,
            HashMap<String,String> model,
            OutputStream output)Fill DOCX template | 
| static void | fillTemplate(String token,
            String docId,
            HashMap<String,String> model,
            String dstPath)Fill document template. | 
| static void | generateSample(int paragraphs,
              OutputStream os)Generate sample docx | 
public static void fillTemplate(InputStream input, HashMap<String,String> model, OutputStream output) throws FileNotFoundException, org.docx4j.openpackaging.exceptions.Docx4JException, JAXBException, IOException
FileNotFoundExceptionorg.docx4j.openpackaging.exceptions.Docx4JExceptionJAXBExceptionIOExceptionpublic static void fillTemplate(String token, String docId, HashMap<String,String> model, String dstPath) throws LockException, PathNotFoundException, AccessDeniedException, RepositoryException, DatabaseException, IOException, org.docx4j.openpackaging.exceptions.Docx4JException, JAXBException, FileSizeExceededException, UserQuotaExceededException, VirusDetectedException, VersionException, ExtensionException, UnsupportedMimeTypeException, ItemExistsException, AutomationException
token - Authentication info.docId - The path that identifies an unique document or its UUID.model - A map with the template keys and values.dstPath - The path of the resulting PDF document (with the name).LockExceptionPathNotFoundExceptionAccessDeniedExceptionRepositoryExceptionDatabaseExceptionIOExceptionorg.docx4j.openpackaging.exceptions.Docx4JExceptionJAXBExceptionFileSizeExceededExceptionUserQuotaExceededExceptionVirusDetectedExceptionVersionExceptionExtensionExceptionUnsupportedMimeTypeExceptionItemExistsExceptionAutomationExceptionpublic static void generateSample(int paragraphs,
                  OutputStream os)
                           throws Exception
ExceptionCopyright © 2015. All Rights Reserved.