Oxygen SDK tutorial

Post here questions and problems related to oXygen frameworks/document types.
Alekso
Posts: 6
Joined: Sat Aug 06, 2016 12:47 pm

Oxygen SDK tutorial

Post by Alekso »

Hi ALL,

Does anybody has tutorial for Oxygen SDK or complete documentation (not so comlicated as official)?

I tried to run mySample\oxygen-sample-plugins\oxygen-sample-plugin-workspace-access as JAR file in plugin directory of Oxygen XML Developer ../lib/WorkspaceAccessPlugin.jar and got "java.lang.ClassNotFoundException".


JAR was prepared with next command:

jar cf WorkspaceAccessPlugin.jar WorkspaceAccessPlugin.class CustomWorkspaceAccessPluginExtension.class CustomWorkspaceAccessOptionPagePluginExtension.class


and plugin.xml was next:

Code: Select all

<?xml version="1.0" encoding="UTF-8"?>
<!-- The plugin.dtd file is located in the OXYGEN_INSATALL_DIR/plugins directory -->
<!DOCTYPE plugin SYSTEM "../plugin.dtd">

<plugin
id="com.oxygenxml.plugin.WorkspaceAccess"
name="CustomWorkspaceAccess"
description="Test"
version="${project.nosnapshot.version}"
vendor="SyncRO"
class="myGroup.workspace.WorkspaceAccessPlugin"
classLoaderType="preferReferencedResources">
<runtime>
<library name="lib/WorkspaceAccessPlugin.jar"/>
</runtime>

<extension type="WorkspaceAccess"
class="myGroup.workspace.CustomWorkspaceAccessPluginExtension"/>
<extension type="OptionPage" class="myGroup.workspace.CustomWorkspaceAccessOptionPagePluginExtension"></extension>

<!--The sample view which will present messages from the sample plugin.-->
<view id="SampleWorkspaceAccessID" initialSide="WEST" initialRow="0"/>
<!--The sample toolbar which will present messages from the sample plugin.-->
<toolbar id="SampleWorkspaceAccessToolbarID" initialSide="NORTH" initialRow="1"/>
</plugin>
Anybody knows how to resolve it? How to compile simple plugins from SDK? :(
Please help me with it.

Thank you in advance,
Alekso
alex_jitianu
Posts: 1008
Joined: Wed Nov 16, 2005 11:11 am

Re: Oxygen SDK tutorial

Post by alex_jitianu »

Hi Alekso,

There is a file mySample/README.html that gives a few hints about what you should do. The main idea is that you should run mvn install in the oxygen-sample-plugin-workspace-access project and afterwards you will have a complete package at : oxygen-sample-plugin-workspace-access/target/oxygen-sample-plugin-workspace-access-{version.number}-plugin.jar. Unzip this archive without creating any additional directories inside {oxygenInstallDir}/plugins.

The manual steps you performed to build the plugin look correct at a first glance. It would help to know to what class the java.lang.ClassNotFoundException refers to. You should also take a look inside the JAR file (just open it like an archive) and see if it has the proper structure with packages and all. You can send us the package you obtain on support@oxygenxml.com and I will take a closer look to see what's missing. Bu anyway, the easiest way to build the plugin package is to use the mvn install command.

Best regards,
Alex
Alekso
Posts: 6
Joined: Sat Aug 06, 2016 12:47 pm

Re: Oxygen SDK tutorial

Post by Alekso »

Hi Alex,

Thanks a lot, I will try it and let you know if it works!

Br,
Alekso
alex_jitianu wrote:Hi Alekso,

There is a file mySample/README.html that gives a few hints about what you should do. The main idea is that you should run mvn install in the oxygen-sample-plugin-workspace-access project and afterwards you will have a complete package at : oxygen-sample-plugin-workspace-access/target/oxygen-sample-plugin-workspace-access-{version.number}-plugin.jar. Unzip this archive without creating any additional directories inside {oxygenInstallDir}/plugins.

The manual steps you performed to build the plugin look correct at a first glance. It would help to know to what class the java.lang.ClassNotFoundException refers to. You should also take a look inside the JAR file (just open it like an archive) and see if it has the proper structure with packages and all. You can send us the package you obtain on support@oxygenxml.com and I will take a closer look to see what's missing. Bu anyway, the easiest way to build the plugin package is to use the mvn install command.

Best regards,
Alex
Alekso
Posts: 6
Joined: Sat Aug 06, 2016 12:47 pm

Re: Oxygen SDK tutorial

Post by Alekso »

Hi Alex,

It works by now as you described. I will try to do something with your SDK with existing documentation on your site.

Thx,
Alekso
Post Reply