* @param tbSoftware
* @throws URISyntaxException
*/
private void attachSoftwareMetadata(Annotation nexAnalysisStep, Software tbSoftware) throws URISyntaxException {
URI tbSoftwarePurl = tbSoftware.getPhyloWSPath().getPurl().toURI();
Annotation nexSoftware = nexAnalysisStep.addAnnotationValue("tb:identifier.software", Constants.TBTermsURI, tbSoftwarePurl);
logger.info("attached software identifier "+tbSoftwarePurl);
// attach software name
if ( null != tbSoftware.getName() ) {
nexSoftware.addAnnotationValue("dc:title", Constants.DCURI, tbSoftware.getName());
logger.info("attached software title");
}
// attach software version
if ( null != tbSoftware.getSoftwareVersion() ) {
nexSoftware.addAnnotationValue("dc:identifier", Constants.DCURI, tbSoftware.getSoftwareVersion());
logger.info("attached software version");
}
// attach software url
if ( null != tbSoftware.getSoftwareURL() ) {
URI tbSoftwareURL = URI.create(tbSoftware.getSoftwareURL());
nexSoftware.addAnnotationValue("dc:source", Constants.DCURI, tbSoftwareURL);
logger.info("attached software url");
}
}