0 Replies Latest reply on Jul 4, 2016 10:09 PM by ???-3 RSS
    ???-3 Explorer

    How to use .properties file in Java Extension



    I'm developing a TW7.0 extension with Eclipse plugin.

    In this plugin, I want to use Jasper(A Library for creating reports in pdf, xlsx, etc...).


    It needs load some .xml files, .properties files  or template files from classpath.

    The names of .xml or .properties files are specified by the library(e.g. jasperreports_extension.properties)

    So I cannot use Properties or Configurations of Thingworx Entities.


    What is the best practices to deal with that kind of library?


    One idea I have come up with is that include a FileRepository in the extension package, get absolute path of

    FileRepository root, and "addClasspath " it at initialization.

    Or, If we can include plane resource files directly into the extension packages,

    it would be very simple although we cannot update the files through the web interfaces.


    Anyway, I would appreciate if someone could give me advice for the ideas, or any other way to do that.