Patrick, it is easier than it looks like. In Eclipse (or the Java view of Domino Designer) you create a plug-in project. There you define the Extension point that makes it an extension library and implement a simple class (mainly returning the version).
Your plug-in.xml would look like this (you might have other content too):
<?xml version="1.0" encoding="UTF-8"?>
<?eclipse version="3.4"?>
<plugin>
<!-- This makes the plug-in an XPages extension library -->
<extension point="com.ibm.commons.Extension">
<service class="com.ibm.ctp.CoreLibrary" type="com.ibm.xsp.Library">
</service>
</extension>
</plugin>
In the manifest (Eclipse has a nice editor, so don't worry) you make sure to export the JDBC driver packages, so they become visible. Finally your activator class looks like this:
import org.eclipse.core.runtime.Plugin;
import org.osgi.framework.BundleContext;
public class Activator extends Plugin {
// The shared instance
private static Activator plugin;
private static String version;
/**
* Returns the shared instance
*
* @return the shared instance
*/
public static CSIActivator getDefault() {
return plugin;
}
public static String getVersion() {
if (version == null) {
try {
version = plugin.getBundle().getHeaders().get("Bundle-Version").toString();
} catch (Exception e) {
e.printStackTrace();
version = "3.7.2";
}
}
return version;
}
public Activator() {
// No Action needed
}
/* (non-Javadoc)
* @see org.eclipse.core.runtime.Plugin#start(org.osgi.framework.BundleContext)
*/
@Override
public void start(final BundleContext context) throws Exception {
super.start(context);
plugin = this;
}
/* (non-Javadoc)
* @see org.eclipse.core.runtime.Plugin#stop(org.osgi.framework.BundleContext)
*/
@Override
public void stop(final BundleContext context) throws Exception {
plugin = null;
super.stop(context);
}
}
Hope that helps