Skip to content

Commit

Permalink
Release 2.6.1
Browse files Browse the repository at this point in the history
Merge branch '2.6.1'
  • Loading branch information
goglepox committed Oct 1, 2013
2 parents 0a65316 + 22433af commit 2c76448
Show file tree
Hide file tree
Showing 37 changed files with 982 additions and 216 deletions.
2 changes: 1 addition & 1 deletion features/net.bioclipse.opentox.ds_feature/feature.xml
Expand Up @@ -2,7 +2,7 @@
<feature
id="net.bioclipse.opentox.ds_feature"
label="OpenTox"
version="2.6.0.vqualifier"
version="2.6.1.qualifier"
provider-name="bioclipse.net"
plugin="net.bioclipse.opentox.ds">

Expand Down
2 changes: 1 addition & 1 deletion features/net.bioclipse.opentox.qsar_feature/feature.xml
Expand Up @@ -2,7 +2,7 @@
<feature
id="net.bioclipse.opentox.qsar_feature"
label="OpenTox QSAR"
version="2.6.0.vqualifier"
version="2.6.1.qualifier"
provider-name="The Bioclipse Team"
plugin="net.bioclipse.opentox.qsar">

Expand Down
7 changes: 1 addition & 6 deletions features/net.bioclipse.opentox.test_feature/feature.xml
Expand Up @@ -2,7 +2,7 @@
<feature
id="net.bioclipse.opentox.test_feature"
label="Bioclipse OpenTox Test Feature"
version="2.6.0.vqualifier"
version="2.6.1.qualifier"
provider-name="The Bioclipse Team"
plugin="net.bioclipse.opentox">

Expand All @@ -22,11 +22,6 @@ This feature and the accompanying materials are made available under the terms o
The Eclipse Public License accompanies this distribution, and is available at http://www.eclipse.org/legal/epl-v10.html
</license>

<url>
<update label="Bioclipse Update Site" url="http://update2.bioclipse.net"/>
<discovery label="The CDK Homepage" url="http://cdk.sf.net"/>
</url>

<requires>
<import feature="net.bioclipse.opentox_feature" version="2.5.0.qualifier"/>
<import feature="net.bioclipse.core_feature" version="2.5.0.qualifier"/>
Expand Down
2 changes: 1 addition & 1 deletion features/net.bioclipse.opentox_feature/feature.xml
Expand Up @@ -2,7 +2,7 @@
<feature
id="net.bioclipse.opentox_feature"
label="Bioclipse OpenTox"
version="2.6.0.vqualifier"
version="2.6.1.qualifier"
provider-name="bioclipse.net"
plugin="net.bioclipse.opentox">

Expand Down
2 changes: 1 addition & 1 deletion features/net.bioclipse.opentox_site/feature.xml
Expand Up @@ -2,7 +2,7 @@
<feature
id="net.bioclipse.opentox_site"
label="Bioclipse-OpenTox Update Site"
version="2.6.0.vqualifier"
version="2.6.1.qualifier"
provider-name="The Bioclipse Team">

<description url="http://www.example.com/description">
Expand Down
27 changes: 27 additions & 0 deletions net.bioclipse.opentox_releng/buckminster.cspec
@@ -0,0 +1,27 @@
<?xml version="1.0" encoding="UTF-8"?>
<cspec xmlns="http://www.eclipse.org/buckminster/CSpec-1.0" name="net.bioclipse.opentox_releng" componentType="buckminster" version="2.6.1">
<dependencies>
<dependency name="net.bioclipse.opentox_site" componentType="eclipse.feature" versionDesignator="0.0.1"/>
<dependency name="org.slf4j.api" componentType="osgi.bundle"/>
<dependency name="log4j.over.slf4j" componentType="osgi.bundle"/>
<dependency name="org.eclipse.rcp" componentType="eclipse.feature"/>
<!--
<dependency name="slf4j.api" componentType="osgi.bundle"/>
<dependency name="jcl.over.slf4j" componentType="osgi.bundle"/>
<dependency name="log4j.over.slf4j" componentType="osgi.bundle"/>
-->
</dependencies>
<actions>
<public name="site.mirror.p2" actor="p2SiteMirror">
<prerequisites>
<attribute name="site.p2" alias="site"/>
</prerequisites>
<products base="${bioclipse.mirror}/${bioclipse.mirror.name}" upToDatePolicy="ACTOR" />
</public>
</actions>
<groups>
<public name="site.p2">
<attribute name="site.p2" component="net.bioclipse.opentox_site"/>
</public>
</groups>
</cspec>
2 changes: 1 addition & 1 deletion plugins/net.bioclipse.opentox.ds/META-INF/MANIFEST.MF
Expand Up @@ -2,7 +2,7 @@ Manifest-Version: 1.0
Bundle-ManifestVersion: 2
Bundle-Name: OpenTox DS
Bundle-SymbolicName: net.bioclipse.opentox.ds;singleton:=true
Bundle-Version: 2.6.0.vqualifier
Bundle-Version: 2.6.1.qualifier
Bundle-Activator: net.bioclipse.opentox.ds.Activator
Bundle-Vendor: The Bioclipse Team
Require-Bundle: org.eclipse.ui,
Expand Down
7 changes: 0 additions & 7 deletions plugins/net.bioclipse.opentox.ds/plugin.xml
Expand Up @@ -18,13 +18,6 @@

</extension>

<extension point="org.eclipse.ui.preferencePages">
<page id="net.bioclipse.opentox.ds.prefs.OpenToxModelsPrefsPage"
name="OpenTox Models"
category="net.bioclipse.opentox.prefs.ServicesPreferencePage"
class="net.bioclipse.opentox.ds.prefs.OpenToxModelsPrefsPage">
</page>
</extension>


</plugin>
Expand Up @@ -9,7 +9,6 @@
import net.bioclipse.ds.model.AbstractDSTest;
import net.bioclipse.ds.model.DSException;
import net.bioclipse.ds.model.ITestResult;
import net.bioclipse.opentox.Activator;
import net.bioclipse.opentox.OpenToxService;
import net.bioclipse.opentox.ServiceReader;
import net.bioclipse.opentox.business.OpentoxManager;
Expand Down Expand Up @@ -67,32 +66,23 @@ protected List<? extends ITestResult> doRunTest(ICDKMolecule cdkmol,
logger.debug("Invoking model: " + model + " for service: " + service);
Map<String, String> OTres = null;
//retry 3 times, looks like a server issue
for (int i=0; i<4 && !monitor.isCanceled(); i++){
if (i>0)
logger.debug(" - Model: " + model + " retry number " + i);

try{
OTres = opentox.predictWithModelWithLabel(service, model, cdkmol, monitor);

} catch (GeneralSecurityException e) {
logger.error(" == Opentox model without access: " + model);
String errorMessage = "No access: " + e.getMessage().toLowerCase();
return returnError(errorMessage, errorMessage);
} catch (UnsupportedOperationException e) {
logger.error(" == Opentox model unavailable: " + model);
String errorMessage = "Unavailable service: " + e.getMessage().toLowerCase();
return returnError(errorMessage, errorMessage);
}catch(Exception e){
logger.error(" == Opentox model calculation failed for: " + model);
logger.debug(e);
String errorMessage =
try{
OTres = opentox.predictWithModelWithLabel(service, model, cdkmol, monitor);

} catch (GeneralSecurityException e) {
logger.error(" == Opentox model without access: " + model);
String errorMessage = "No access: " + e.getMessage().toLowerCase();
return returnError(errorMessage, errorMessage);
} catch (UnsupportedOperationException e) {
logger.error(" == Opentox model unavailable: " + model);
String errorMessage = "Unavailable service: " + e.getMessage().toLowerCase();
return returnError(errorMessage, errorMessage);
}catch(Exception e){
logger.error(" == Opentox model calculation failed for: " + model);
logger.debug(e);
String errorMessage =
"Error during calculation: " + e.getMessage();
return returnError(errorMessage, errorMessage);
}

//End if we have results
if (OTres!=null) break;

return returnError(errorMessage, errorMessage);
}

if (OTres==null || OTres.size()<=0){
Expand Down
2 changes: 1 addition & 1 deletion plugins/net.bioclipse.opentox.qsar/META-INF/MANIFEST.MF
Expand Up @@ -2,7 +2,7 @@ Manifest-Version: 1.0
Bundle-ManifestVersion: 2
Bundle-Name: OpenTox QSAR
Bundle-SymbolicName: net.bioclipse.opentox.qsar;singleton:=true
Bundle-Version: 2.6.0.vqualifier
Bundle-Version: 2.6.1.qualifier
Bundle-Activator: net.bioclipse.opentox.qsar.Activator
Require-Bundle: org.eclipse.ui,
org.eclipse.core.runtime,
Expand Down
Expand Up @@ -3,11 +3,15 @@
import org.apache.log4j.Logger;

import java.util.ArrayList;
import java.util.Collection;
import java.util.Collections;
import java.util.List;

import net.bioclipse.core.business.BioclipseException;
import net.bioclipse.core.domain.IStringMatrix;
import net.bioclipse.opentox.Activator;
import net.bioclipse.opentox.OpenToxService;
import net.bioclipse.opentox.ServiceReader;
import net.bioclipse.opentox.business.IOpentoxManager;
import net.bioclipse.qsar.descriptor.IDescriptorCalculator;
import net.bioclipse.qsar.descriptor.model.DescriptorImpl;
Expand Down Expand Up @@ -128,20 +132,26 @@ public List<DescriptorProvider> discoverProvidersAndImpls() {
}


private ArrayList<OpenToxProvider> discoverProviders() {
private List<OpenToxProvider> discoverProviders() {

ArrayList<OpenToxProvider> endpoints = new ArrayList<OpenToxProvider>();

List<OpenToxService> services = ServiceReader
.readServicesFromPreferences();
if ( services.isEmpty() ) {
logger.error( "Could not find an OpenTox service" );
return Collections.emptyList();
}
OpenToxService service = services.get( 0 );
//Add a service
OpenToxProvider s1 = new OpenToxProvider(
"opentox.provider",
"Opentox",
"http://apps.ideaconsult.net:8080/ambit2/",
"http://apps.ideaconsult.net:8080/ontology/");
OpenToxProvider s1 = new OpenToxProvider( "opentox.provider",
service.getName(),
service.getService(),
service.getServiceSPARQL() );

endpoints.add(s1);
endpoints.add( s1 );

//TODO: add more here or discover it
// TODO: add more here or discover it


return endpoints;
Expand Down
2 changes: 1 addition & 1 deletion plugins/net.bioclipse.opentox.test/META-INF/MANIFEST.MF
Expand Up @@ -2,7 +2,7 @@ Manifest-Version: 1.0
Bundle-ManifestVersion: 2
Bundle-Name: Bioclipse-OpenTox Unit Tests
Bundle-SymbolicName: net.bioclipse.opentox.test
Bundle-Version: 2.6.0.vqualifier
Bundle-Version: 2.6.1.qualifier
Bundle-Activator: net.bioclipse.opentox.test.Activator
Require-Bundle: org.eclipse.ui,
org.eclipse.core.runtime,
Expand Down
5 changes: 3 additions & 2 deletions plugins/net.bioclipse.opentox.ui/META-INF/MANIFEST.MF
Expand Up @@ -2,7 +2,7 @@ Manifest-Version: 1.0
Bundle-ManifestVersion: 2
Bundle-Name: OpenTox UI
Bundle-SymbolicName: net.bioclipse.opentox.ui;singleton:=true
Bundle-Version: 2.6.0.vqualifier
Bundle-Version: 2.6.1.qualifier
Bundle-Activator: net.bioclipse.opentox.ui.Activator
Bundle-Vendor: The Bioclipse Team
Require-Bundle: org.eclipse.ui,
Expand All @@ -13,7 +13,8 @@ Require-Bundle: org.eclipse.ui,
net.bioclipse.cdk.business;bundle-version="2.5.0",
net.bioclipse.core;bundle-version="2.5.0",
net.bioclipse.browser;bundle-version="2.5.0",
net.bioclipse.usermanager;bundle-version="2.5.0"
net.bioclipse.usermanager;bundle-version="2.5.0",
org.eclipse.help;bundle-version="3.6.0"
Bundle-RequiredExecutionEnvironment: JavaSE-1.6
Bundle-ActivationPolicy: lazy
Import-Package: org.apache.log4j
Expand Down
14 changes: 14 additions & 0 deletions plugins/net.bioclipse.opentox.ui/html/about.html
@@ -0,0 +1,14 @@
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML>
<HEAD>
<META HTTP-EQUIV="CONTENT-TYPE" CONTENT="text/html; charset=utf-8">
<TITLE>About Bioclipse</TITLE>
<link rel="stylesheet" href="../../PRODUCT_PLUGIN/narrow_book.css" type="text/css">
</HEAD>
<BODY LANG="en-US" DIR="LTR">

<h1>About OpenTox</h1>
OpenTox is a web framework that supports the building of toxicology models, validation and open data exchange. Read more about the OpenTox project on their <a href="http://www.opentox.org/">website</a>. Bioclipse uses the OpenTox web-service to evaluate the toxicity properties in various molecules, for example in the decision support feature.<br/><br/>
To use all funktions in the OpenTox feature you need to register an account on OpenToxs website, but several functions will work any way. Also worth to mention is that some of the models in the decision suport feature needs an Opentox account. If you want to create an account for OpenTox, click <a href="http://www.opentox.org/join_form">here</a> to get to the OpenTox registration form. Then you need to provide Bioclipse with the login information, see <a href="./install.html">Install OpenTox in Bioclipse</a>
</BODY>
</HTML>
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
16 changes: 16 additions & 0 deletions plugins/net.bioclipse.opentox.ui/html/install.html
@@ -0,0 +1,16 @@
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML>
<HEAD>
<META HTTP-EQUIV="CONTENT-TYPE" CONTENT="text/html; charset=utf-8">
<TITLE>About Bioclipse</TITLE>
<link rel="stylesheet" href="../../PRODUCT_PLUGIN/narrow_book.css" type="text/css">
</HEAD>
<BODY LANG="en-US" DIR="LTR">
<h1>Install OpenTox in Bioclipse</h1>
When the OpenTox feature is installed, which most likely is the case if you read this, you will also need a login to the OpenTox web-services. If you don't have that you can register <a href="http://www.opentox.org/join_form">here</a>.<br/>
Bioclipse handles that as an account under your user account (Don't have any? Don't worry, just continue reading and we sort it out). To create this OpenTox-account, choose <b>File > New...</b> and select <b>General > Account</b> in the tree-menu that appears. Then click <b>next</b>, now you will be asked to login to your Bioclipse user account, or if there's no user account yet to create one. You can read more about Bioclipse user account in <a href="../../net.bioclipse.ui/html/usermanager/introduction.html">Bioclipse user account</a> then the Bioclipse user manual. Fill in your username and password and click on the <b>Next</b>-button.<br/><br/>
<img src="images/OpenToxAccount.png" width="350" align="right">
The next page should look simular to the picture to the right, make sure that "OpenTox" is selected in the drop-down menu. Fill in your OpenTox username and password in the respective text-boxes. If you for some reason want to use an other OpenSSO than the default you may change that in the text-box with the text "auth. service" (short for "authorization service") in front. You may also choose an own name for your account, this is done in the text-box just beneath the drop-down menu. <br/><br/>
When you are satisfied with your settings press the <b>Finish</b>-button, and if everything goes well the padlock in the bottom of the Bioclipse window turns green. If for some reason it doesn't, please check the settings of your account in preferences. For more information check the section <a href="preferences.html">OpenTox preferences</a> or the more general <a href="../../net.bioclipse.ui/html/usermanager/usingPrefs.html">Using preferences</a> in the Bioclipse users manual/Bioclipse user account.
</BODY>
</HTML>
20 changes: 20 additions & 0 deletions plugins/net.bioclipse.opentox.ui/html/preferences.html
@@ -0,0 +1,20 @@
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML>
<HEAD>
<META HTTP-EQUIV="CONTENT-TYPE" CONTENT="text/html; charset=utf-8">
<TITLE>About Bioclipse</TITLE>
<link rel="stylesheet" href="../../PRODUCT_PLUGIN/narrow_book.css" type="text/css">
</HEAD>
<BODY LANG="en-US" DIR="LTR">
<h1>OpenTox preferences</h1>
Because the login settings for the OpenTox web-service are handled as an account under your Bioclipse user account while other settings are global (i.e. same for all users), the preferences are divided between two different parts of the Bioclipse preferences. <br/><br/>
<h2>Main preferences</h2>
The settings that are common for all OpenTox-accounts in Bioclipse are gathered under the <b>OpenTox</b>-tab in Bioclipse preferences, see the image below. Right now it is only possible to add, edit or delete the service-site and serviceSPARQL-site for OpenTox. Observe that only the service on the top row of the list is used. You can move the items in the list with help of the <b>Up</b> and <b>Down</b> buttons to the right of the list.<br/>
The usage of OpenSSO is administrated via your OpenTox-account, <a href="#upref">see below </a>. This gives different users the opportunity to use different OpenSSO-services in the same installation of Bioclipse without changing the preferences all the time. <br/><br/>
<img src="images/OTPrefs.png" width="450"><br/><br/>
<a name="upref"><h2>OpenTox user preferences</h2></a>
To edit your login information to the OpenTox web-service (i.e. the OpenSSO) and which OpenSSO service you use, you need to open the preferences for your user account. Open the <b>User</b>-tab in Bioclipse preferences and select your user account, then press the <b>Edit...</b>-button. You will now be asked for the password to your Bioclipse user account, fill it in and press <b>Ok</b>.<br/><br/>
Now a window that looks simular to the one in the image below appears. Choose your OpenTox-account in the list to the left (1). Then you can edit your settings for it either in the spread sheet to the right (2), or by pressing <b>Edit account...</b> (3) beneath the list with the accounts, and then change the dialog (4) that then appears. If you want to know more about the user preferences, you can read about it in <a href="../../net.bioclipse.ui/html/usermanager/usingPrefs.html">Using preferences</a> in the Bioclipse users manual / Bioclipse user account. <br/><br/>
<img src="images/OTUserPref.png" width="450">
</BODY>
</HTML>
12 changes: 12 additions & 0 deletions plugins/net.bioclipse.opentox.ui/html/scripting.html
@@ -0,0 +1,12 @@
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML>
<HEAD>
<META HTTP-EQUIV="CONTENT-TYPE" CONTENT="text/html; charset=utf-8">
<TITLE>About Bioclipse</TITLE>
<link rel="stylesheet" href="../../PRODUCT_PLUGIN/narrow_book.css" type="text/css">
</HEAD>
<BODY LANG="en-US" DIR="LTR">
<h1>OpenTox scripting</h1>
Writing and running JavaScripts in Bioclipse is a powerful way to analyse molecules with the help of the different models and datasets that the OpenTox framework is providing. The different commands related to OpenTox start with the prefix "openTox.", e.g. to create a new dataset you can use the command "opentox.createDataset". All commands that you can use are listed <a href="../../net.bioclipse.doc/html/index.html#opentox">here</a>, and you can find an introduction to scripting <a href="../../net.bioclipse.doc/html/scriptingBioclipse.html">here</a>.
</BODY>
</HTML>
7 changes: 7 additions & 0 deletions plugins/net.bioclipse.opentox.ui/plugin.xml
Expand Up @@ -54,6 +54,13 @@
</menu>
</menuContribution>
</extension>
<extension
point="org.eclipse.help.toc">
<toc
file="toc.xml"
primary="true">
</toc>
</extension>



Expand Down
21 changes: 21 additions & 0 deletions plugins/net.bioclipse.opentox.ui/toc.xml
@@ -0,0 +1,21 @@
<?xml version="1.0" encoding="UTF-8"?>
<?NLS TYPE="org.eclipse.help.toc"?>

<toc label="OpenTox">
<topic
href="html/about.html"
label="About OpenTox">
</topic>
<topic
href="html/Install.html"
label="Install OpenTox in Bioclipse">
</topic>
<topic
href="html/preferences.html"
label="OpenTox preferences">
</topic>
<topic
href="html/scripting.html"
label="OpenTox scripting">
</topic>
</toc>
2 changes: 1 addition & 1 deletion plugins/net.bioclipse.opentox/META-INF/MANIFEST.MF
Expand Up @@ -2,7 +2,7 @@ Manifest-Version: 1.0
Bundle-ManifestVersion: 2
Bundle-Name: Bioclipse OpenTox Plugin
Bundle-SymbolicName: net.bioclipse.opentox; singleton:=true
Bundle-Version: 2.6.0.vqualifier
Bundle-Version: 2.6.1.qualifier
Bundle-Activator: net.bioclipse.opentox.Activator
Export-Package: net.bioclipse.opentox,
net.bioclipse.opentox.api,
Expand Down

0 comments on commit 2c76448

Please sign in to comment.