com.hp.hpl.jena.shared.CannotEncodeCharacterException: cannot encode (char) in contentXML

Coderanch | wei liu | 7 years ago
  1. 0

    JenaOWLModel save() throw errors when trying to save a very big object

    Coderanch | 7 years ago | wei liu
    com.hp.hpl.jena.shared.CannotEncodeCharacterException: cannot encode (char) in contentXML

    Root Cause Analysis

    1. com.hp.hpl.jena.shared.CannotEncodeCharacterException

      cannot encode (char) in contentXML

      at com.hp.hpl.jena.rdf.model.impl.Util.substituteEntitiesInElementContent()
    2. Apache Jena - Core
      Util.substituteEntitiesInElementContent
      1. com.hp.hpl.jena.rdf.model.impl.Util.substituteEntitiesInElementContent(Util.java:153)
      1 frame
    3. Jena
      BaseXMLWriter.write
      1. com.hp.hpl.jena.xmloutput.impl.Basic.writeLiteral(Basic.java:174)
      2. com.hp.hpl.jena.xmloutput.impl.Basic.writePredicate(Basic.java:104)
      3. com.hp.hpl.jena.xmloutput.impl.Basic.writeRDFStatements(Basic.java:77)
      4. com.hp.hpl.jena.xmloutput.impl.Basic.writeRDFStatements(Basic.java:66)
      5. com.hp.hpl.jena.xmloutput.impl.Basic.writeBody(Basic.java:40)
      6. com.hp.hpl.jena.xmloutput.impl.BaseXMLWriter.writeXMLBody(BaseXMLWriter.java:455)
      7. com.hp.hpl.jena.xmloutput.impl.BaseXMLWriter.write(BaseXMLWriter.java:424)
      7 frames
    4. edu.stanford.smi
      JenaOWLModel.save
      1. edu.stanford.smi.protegex.owl.jena.JenaOWLModel.saveModel(Unknown Source)
      2. edu.stanford.smi.protegex.owl.jena.JenaOWLModel.save(Unknown Source)
      3. edu.stanford.smi.protegex.owl.jena.JenaOWLModel.save(Unknown Source)
      4. edu.stanford.smi.protegex.owl.jena.protege2jena.Protege2Jena.saveAll(Unknown Source)
      5. edu.stanford.smi.protegex.owl.jena.JenaOWLModel.save(Unknown Source)
      5 frames
    5. MiningExtract
      BuildHealthProvider.main
      1. MiningExtract.BuildHealthProvider.IntegrateOntology(BuildHealthProvider.java:1453)
      2. MiningExtract.BuildHealthProvider.main(BuildHealthProvider.java:1692)
      2 frames