Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » Gendoc » gendoc build with maven
gendoc build with maven [message #1783743] Fri, 16 March 2018 13:22 Go to next message
smaoui asma is currently offline smaoui asmaFriend
Messages: 50
Registered: July 2009
Location: Paris Saclay, France
Member
Hello,
I generate doc from my Papyurs model using gendoc
when running the application in local (second instance of Eclipse) all works fine However, when building using jenkins, I do not got a compilation error, but when generating the documenation I got this error :

java.net.URISyntaxException: Relative path in absolute URI: jar://file:/C:/Users/AS247872/Downloads/myTool/papyrus/plugins/com.cea.papyrus.gendoc.custom.templates_0.7.0.201803161152.jar!/resources/TemplateReport.docx
at java.net.URI.checkPath(Unknown Source)
at java.net.URI.<init>(Unknown Source)
at org.eclipse.core.runtime.URIUtil.toURI(URIUtil.java:295)
at org.eclipse.gendoc.wizard.GendocWizard$2.run(GendocWizard.java:154)

I added the template path in the class Gendoc2RunnerDocxRequirements implements IGendocTemplate as follow:

@Override
public String getOutPutExtension() {
return "docx";
}

public URL getTemplate() {
return Activator.getDefault().getBundle().getEntry("/resources/FaceReport.docx");
}


Any idea to solve this issue ?

Thanks

Asma
Re: gendoc build with maven [message #1783912 is a reply to message #1783743] Tue, 20 March 2018 10:10 Go to previous messageGo to next message
Antonio Campesino is currently offline Antonio CampesinoFriend
Messages: 56
Registered: August 2016
Member
Hi,

It looks the URIUtil.toURI() does not like that URI. We use the file locator to covert "bundle:" URLs to java standard URLs. Something in the process it didn't go well.

One thing you can try is to force the plugin to unpack when it is installed, in that way, the URI will ends up being a file and that translation will be properly done. You can do that in the feature including the plugin, in the plugin list, select your plugin and check "Unpack the plug-in archive after installation".

Regards,
Antonio.
Re: gendoc build with maven [message #1783913 is a reply to message #1783912] Tue, 20 March 2018 10:16 Go to previous messageGo to next message
Antonio Campesino is currently offline Antonio CampesinoFriend
Messages: 56
Registered: August 2016
Member
Hi again,

I also use the header "Eclipse-BundleShape: dir" in the plugin manifest to force unpack the plugin after installing it... You probably need only that, I have also marked in the feature.

Regards,
Antonio
Re: gendoc build with maven [message #1784009 is a reply to message #1783913] Wed, 21 March 2018 13:47 Go to previous message
smaoui asma is currently offline smaoui asmaFriend
Messages: 50
Registered: July 2009
Location: Paris Saclay, France
Member
Hello,

Thank you for your answer. It works now when unpacking the plugin ;) and removing the "/" at the begining of the path given to getEntry() method

Regards,
Asma
Previous Topic:no image can be generated for Diagram
Next Topic:Not able to retrieve SysML 1.4 Internal Block Diagram
Goto Forum:
  


Current Time: Thu Apr 25 17:33:55 GMT 2024

Powered by FUDForum. Page generated in 0.03158 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top