On 8/31/21 11:21, Madlik, Monika (LNG-VIE) wrote:

I'm sure we didn't write this command "MultiPick" by our own in 2007. A colleague of me did the configurations at this time but unfortunately he is not part of our company any more so I can't ask him about how he did the config of this file. But in mail-archive I found the old conversation between you and Roman: https://www.mail-archive.com/xmleditor-support@xmlmind.com/msg07205.html <https://www.mail-archive.com/xmleditor-support@xmlmind.com/msg07205.html> Maybe this helps. And this is also the reason why this java command has this package name.

Understood.

Please note that we have no connection whatsoever with the author Alain Pierrot, who happens to be just one of our customers.




As this is a file written by Alain Pierrot, I hoped I can use this in the old version as well as in the new one.

I don't think any custom Java code which compiled successfully against XXE v3 codebase could compile (or dynamically load) successfully against XXE v9 codebase.

The "java.lang.reflect.InvocationTargetException" exception you reported below is just another issue illustrating this.

However, porting this custom Java code to XXE v9 should be pretty straightforward as we basically renamed some classes and some packages (e.g. com.xmlmind.xmleditapp.docbook --> com.xmlmind.xmleditext.docbook).





And I also did as you reccomended:

I cleared the folder XXE_install_dir/addon and only put my .jar-file to the folder %APPDATA%\XMLmind\XMLEditor9. I deleted the quick start cache and restartet XMLMind.

And I started xxe-c.bat via the commandline. These are the messages I get when I open an artikel.xml-file:

G:\XMLMind_v9\bin>style sheet 'file:/G:/XMLMind_v9/addon/config/artikel/css/artikel.css': cannot invoke constructor com.xmlmind.xmleditapp.docbook.TableSupport(String[], StyleViewFactory): java.lang.reflect.InvocationTargetException

+---------------------------------------
CAUSE:
java.lang.NoSuchMethodError: 'void com.xmlmind.xmledit.styledview.CustomViewManager$NamePattern.<init>(com.xmlmind.xmledit.xmlutil.Namespace, java.lang.String)'
+---------------------------------------
+---------------------------------------

But I think these messages are related to a table-extension I added and not to the MultiPick-command.

That's right.

My guess is that your "artikel.css" contains directly or indirectly (i.e. @import "SOMETHING.css" or @import "SOMETHING.imp") the following statement:

@extension "com.xmlmind.xmleditapp.docbook.TableSupport true";

which must be replaced by:

@extension "com.xmlmind.xmleditext.docbook.TableSupport true";

The above statement is found in our stock:
XXE_install_dir/addon/config/docbook/css/html_cals_table.imp

Better recommendation below though.




And I got the information from the "About"-Window:


  * G:\XMLMind_v9\addon\config\aktuelles\aktuelles.xxe
  * G:\XMLMind_v9\addon\config\artikel\artikel.xxe
  * G:\XMLMind_v9\addon\config\handbuch\handbuch.xxe

You got 3 custom configurations discovered and loaded by XXE.




    XML catalogs

  * G:\XMLMind_v9\addon\config\aktuelles\aktuelles_catalog.xml
  * G:\XMLMind_v9\addon\config\artikel\artikel_catalog.xml
  * G:\XMLMind_v9\addon\config\handbuch\handbuch_catalog.xml

You got 3 custom XML catalogs discovered and loaded by XXE.




Class path
C:\Users\MadlikM\AppData\Roaming\XMLmind\XMLEditor9\addon\xxe_app.jar
C:\Users\MadlikM\AppData\Roaming\XMLmind\XMLEditor9\addon\xxe_ln.jar

Some custom code successfully discovered and loaded by XXE.




G:\XMLMind_v9\addon\config\artikel\docbook-xsl-saxon.jar
G:\XMLMind_v9\addon\config\artikel\docbook.jar

docbook-xsl-saxon.jar, docbook.jar are already found in the distribution. Therefore not only these are not useful but also could break XXE.



G:\XMLMind_v9\addon\config\artikel\FileWriteProtected.jar
G:\XMLMind_v9\addon\config\artikel\MultiPick.jar
G:\XMLMind_v9\addon\config\artikel\SearchFilesInFolder.jar

Some custom code successfully discovered and loaded by XXE.



G:\XMLMind_v9\addon\config\handbuch\docbook-xsl-saxon.jar
G:\XMLMind_v9\addon\config\handbuch\docbook.jar

docbook-xsl-saxon.jar, docbook.jar are already found in the distribution. Therefore not only these are not useful but also could break XXE v9.



G:\XMLMind_v9\addon\config\handbuch\FileWriteProtected.jar
G:\XMLMind_v9\addon\config\handbuch\SearchFileInFolders.jar

Duplicate custom code?



G:\XMLMind_v9\addon\xxe_app.jar
G:\XMLMind_v9\addon\xxe_ln.jar

Duplicate custom code?




--> Given the above very useful report, we strongly recommend:

1) To reinstall XXE v9 and to completely delete your C:\Users\MadlikM\AppData\Roaming\XMLmind\ to get a fresh, stable, start.

2) To port your customizations *by* *the* *book* to XXE v9 starting from the Java and XML source files.

- While doing this, please do not duplicate any .jar file already found in the stock distribution.

- While doing this, please do not bother with low-level declarations like @extension "com.xmlmind.xmleditext.docbook.TableSupport true";

Instead simply start your "artikel.css" with:

@import url(docbook-config:css/docbook.css);

then add your own styles.

This is precisely what we call "by the book".
* "XMLmind XML Editor - Configuration and Deployment", http://www.xmlmind.com/xmleditor/_distrib/doc/configure/index.html
* "XMLmind XML Editor - Developer's Guide"
http://www.xmlmind.com/xmleditor/_distrib/doc/dev/index.html

3) Once you have done this, to copy your configurations and your .jar files *only* *to* C:\Users\MadlikM\AppData\Roaming\XMLmind\XMLEditor9\addon\ln\ to clear the quick start cache and to start XXE.

Notice the ln\ subdirectory which itself may contain sub-subdirectories and files artikel\ , aktuelles\, handbuch\, xxe_ln.jar, etc.

In our opinion, this is the only way to obtain a simple, reliable, maintainable, customization.







--
XMLmind XML Editor Support List
xmleditor-support@xmlmind.com
http://www.xmlmind.com/mailman/listinfo/xmleditor-support

Reply via email to