Bug #1241

Search Results Data/Nodata icons not working for EML2

Added by Matthew Brooke over 18 years ago. Updated over 17 years ago.

morpho - query
Target version:
Start date:
Due date:
% Done:


Estimated time:


In the search results dialog, the icons on the left showing "has data" (red
icon) or "description only" (blue icon) always show blue for eml2 packages, even
if they have data. This is because the code in is still

Also need to check other classes in query package to ensure no beta 6 dependencies

Suggested fix:

1) pull this eml-verion-specific code into the eml-verion-specific datapackage
object, and access it via a static method (public static boolean hasData, so an
entire datapackage doesn't need to be instantiated to call it (since we're only
looking at search results, not opening the entire packages yet).

2) In DataPackageFactory, factor our the code that determines doctype (or eml
version) into a public method, so the resultset can call this method and pass it
the xml file in question, eg:

public static String getDPInstanceNameForDataPackage(xmlDocToInspect)

The method will return the string name of the correct datapackage class version
(eg ""), so the resultset
can do a class.forName() and get the datapackage class to call the
above-mentioned static method.

Related issues

Has duplicate Morpho - Bug #942: wrong icon appears for data in package from metacatResolved01/10/2003


#1 Updated by Dan Higgins over 18 years ago

The problem here is complicated by the fact that the resultSet returned by a
metacat query does not automatically return information about the existence of
data in the package. Previously, the triples (which are part of the ResultSet)
were examined for a link to a datafile.

To handle the case for eml2 without changing metacat, we will need to add
returnField parameters to the query.

#2 Updated by Andrea Andrea over 17 years ago

duplicate of bug 942

  • This bug has been marked as a duplicate of 942 ***

#3 Updated by Redmine Admin over 9 years ago

Original Bugzilla ID was 1241

Also available in: Atom PDF