*/
public class FeaturesFile extends AlignFile implements FeaturesSourceI
{
- /*
- * map-valued attributes are prefixed with this for output to GFF3;
- * the prefix is removed if found on reading
- */
- public static final String MAP_ATTRIBUTE_PREFIX = "jvmap_";
+ private static final String EQUALS = "=";
private static final String TAB_REGEX = "\\t";
private static final String ID_NOT_SPECIFIED = "ID_NOT_SPECIFIED";
- private static final String NOTE = "Note";
-
protected static final String GFF_VERSION = "##gff-version";
private AlignmentI lastmatchedAl = null;
{
String formatted = StringUtils.urlEncode(value.toString(),
GffHelperI.GFF_ENCODABLE);
- sb.append(key).append("=").append(formatted);
+ sb.append(key).append(EQUALS).append(formatted);
}
}
}
* Formats the map entries as
*
* <pre>
- * jvmap_key={key1=value1,key2=value2,...}
+ * key=key1=value1,key2=value2,...
* </pre>
*
* and appends this to the string buffer
* AbstractMap.toString would be a shortcut here, but more reliable
* to code the required format in case toString changes in future
*/
- sb.append(MAP_ATTRIBUTE_PREFIX).append(key).append("={");
+ sb.append(key).append(EQUALS);
boolean first = true;
for (Entry<?, ?> entry : map.entrySet())
{
sb.append(",");
}
first = false;
- sb.append(entry.getKey().toString()).append("=");
+ sb.append(entry.getKey().toString()).append(EQUALS);
String formatted = StringUtils.urlEncode(entry.getValue().toString(),
GffHelperI.GFF_ENCODABLE);
sb.append(formatted);
}
- sb.append("}");
}
/**