Class CTeUtil

java.lang.Object
org.brerp.sped.cte.util.CTeUtil

public abstract class CTeUtil extends Object
  • Field Details

  • Constructor Details

    • CTeUtil

      public CTeUtil()
  • Method Details

    • getAttachmentEntryFile

      public static File getAttachmentEntryFile(MAttachmentEntry entry)
      Get Attachment
      Parameters:
      entry -
      Returns:
    • getJasperDACTeTpImpressao

      public static String getJasperDACTeTpImpressao(MCTECTe cte)
    • getJasperPrint

      public static net.sf.jasperreports.engine.JasperPrint getJasperPrint(Map<String,Object> parameters, File xmlCTe, File jasperFile) throws net.sf.jasperreports.engine.JRException, AdempiereException, IOException
      Cria o JasperPrint a Partir de um XML.
      Parameters:
      parameters -
      xmlCTe -
      jasperFile -
      Returns:
      Throws:
      net.sf.jasperreports.engine.JRException
      AdempiereException
      IOException
    • printDACTe

      public static String printDACTe(net.sf.jasperreports.engine.JasperPrint jasperPrint, PrintInfo printInfo) throws IOException, net.sf.jasperreports.engine.JRException
      Throws:
      IOException
      net.sf.jasperreports.engine.JRException
    • printDACTe

      public static String printDACTe(List<net.sf.jasperreports.engine.JasperPrint> jasperPrintList, PrintInfo printInfo) throws IOException, net.sf.jasperreports.engine.JRException
      Throws:
      IOException
      net.sf.jasperreports.engine.JRException
    • generateDistribution

      public static File generateDistribution(MCTECTe cte) throws Exception
      Throws:
      Exception
    • geraRodapDistribuicao

      public static br.com.swconsultoria.cte.schema_400.procCTe.TProtCTe geraRodapDistribuicao(String chCTe, String nProt, String tpAmb, String dhRecbto, String digVal, String cStat, String xMotivo, String verAplic)
      Rodapé padrão Distribuição
      Parameters:
      chCTe -
      nProt -
      tpAmb -
      dhRecbto -
      digVal -
      cStat -
      xMotivo -
      Returns:
      XML
    • getCTeStatus

      public static String getCTeStatus(String status)
    • updateAttach

      public static void updateAttach(MCTECTe cte, File xml)
      update Attachment
      Parameters:
      cte -
      xml -
    • genDACTe

      public static File genDACTe(MCTECTe cte, File xml) throws Exception
      Throws:
      Exception
    • getPDF

      public static File getPDF(net.sf.jasperreports.engine.JasperPrint jasperPrint, String fileName) throws IOException, net.sf.jasperreports.engine.JRException
      Throws:
      IOException
      net.sf.jasperreports.engine.JRException
    • getParametersDacte

      public static Map<String,Object> getParametersDacte(MCTECTe cte, File jasper)
      Preenche os Parâmetros da DANFe Frente msgVersaoTeste PreImpresso msgPrevisualizacao
      Returns: