Class EnrichmentJSONProcessor
- java.lang.Object
-
- org.intermine.webservice.server.widget.EnrichmentJSONProcessor
-
- All Implemented Interfaces:
WidgetResultProcessor
public final class EnrichmentJSONProcessor extends java.lang.Object implements WidgetResultProcessor
- Author:
- Alex Kalderimis
-
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description java.lang.String
formatExtraAttributes(java.util.Map<java.lang.String,java.util.Map<java.lang.String,java.lang.Object>> extraAttributes)
Format the value of extraAttribute.java.util.List<java.lang.String>
formatRow(java.util.List<java.lang.Object> row)
Format a list of objects into a string representation.static WidgetResultProcessor
instance()
-
-
-
Method Detail
-
instance
public static WidgetResultProcessor instance()
- Returns:
- A widget result processor
-
formatRow
public java.util.List<java.lang.String> formatRow(java.util.List<java.lang.Object> row)
Description copied from interface:WidgetResultProcessor
Format a list of objects into a string representation.- Specified by:
formatRow
in interfaceWidgetResultProcessor
- Parameters:
row
- The widget's results.- Returns:
- A list of strings.
-
formatExtraAttributes
public java.lang.String formatExtraAttributes(java.util.Map<java.lang.String,java.util.Map<java.lang.String,java.lang.Object>> extraAttributes) throws org.json.JSONException
Format the value of extraAttribute. E.g. "{"gene_length":{"percentage_gene_length_not_null":"22.58%","gene_length_correction":"false"- Parameters:
extraAttributes
- The attributes to format.- Returns:
- A string with all the extra attributes.
- Throws:
org.json.JSONException
- if we can't serialise them
-
-