fr.paris.lutece.plugins.ods.service.manager
Class DocumentManager

java.lang.Object
  extended by fr.paris.lutece.plugins.ods.service.manager.DocumentManager

public final class DocumentManager
extends java.lang.Object

Classe qui a pour responsabilité de faire le proxy entre l'application ODS et l'outil utilisé pour généré les documents PDF


Field Summary
static java.lang.String CONSTANTE_ODT
           
static java.lang.String PDF_CONVERSION
           
static java.lang.String PDF_WORD
           
 
Method Summary
static boolean checkJCopist()
          Teste la connexion au serveur JCopist.
static byte[] convert(java.lang.String strFormatConversion, java.lang.String strNameTemplate, byte[] xml)
          Cette méthode permet de convertir un fichier XML en un fichier PDF
static void deployTemplateService(java.lang.String pathTemplate, java.lang.String nameTemplate)
          Deploie une nouvelle template
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

PDF_CONVERSION

public static final java.lang.String PDF_CONVERSION
See Also:
Constant Field Values

CONSTANTE_ODT

public static final java.lang.String CONSTANTE_ODT
See Also:
Constant Field Values

PDF_WORD

public static final java.lang.String PDF_WORD
See Also:
Constant Field Values
Method Detail

convert

public static byte[] convert(java.lang.String strFormatConversion,
                             java.lang.String strNameTemplate,
                             byte[] xml)
                      throws net.sf.jcopist.service.exception.UnavailableException,
                             net.sf.jcopist.service.exception.ServerException,
                             java.io.IOException
Cette méthode permet de convertir un fichier XML en un fichier PDF

Parameters:
strFormatConversion - Format de la conversion tel que PDF ou DOC
strNameTemplate - Nom de la template utilisé
xml - fichier XML
Returns:
le pdf généré
Throws:
net.sf.jcopist.service.exception.UnavailableException - UnavailableException
net.sf.jcopist.service.exception.ServerException - ServerException
java.io.IOException - IOException

deployTemplateService

public static void deployTemplateService(java.lang.String pathTemplate,
                                         java.lang.String nameTemplate)
                                  throws java.lang.Exception
Deploie une nouvelle template

Parameters:
pathTemplate - le path de la template
nameTemplate - le nom de la template
Throws:
java.lang.Exception - if an error occurs.

checkJCopist

public static boolean checkJCopist()
Teste la connexion au serveur JCopist.

Returns:
TRUE si le test s'est bien déroulé, FALSE sinon


Copyright © 2010 Mairie de Paris. All Rights Reserved.