[Biojava-dev] SimpleGFFRecord
Richard Holland
holland at ebi.ac.uk
Fri Jan 19 15:54:45 UTC 2007
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
Thanks for pointing this out. I have fixed it on the HEAD branch of CVS.
cheers,
Richard
Ido M. Tamir wrote:
> Hi,
> SimpleGFFRecord puts out one additional semicolon
> at the end of the attributes. Shifting sBuff.append(";")
> to the test changes that.
>
> old:
>
> public static String stringifyAttributes(Map attMap) {
> StringBuffer sBuff = new StringBuffer();
> Iterator ki = attMap.keySet().iterator();
> while (ki.hasNext()) {
> String key = (String) ki.next();
> sBuff.append(key);
> List values = (List) attMap.get(key);
> for (Iterator vi = values.iterator(); vi.hasNext();) {
> String value = (String) vi.next();
> if (isText(value)) {
> sBuff.append(" \"" + value + "\"");
> } else {
> sBuff.append(" " + value);
> }
> }
> sBuff.append(";"); <---!!
> if (ki.hasNext()) {
> sBuff.append(" ");
> }
> }
> return sBuff.substring(0);
> }
>
>
> public static String stringifyAttributes(Map attMap) {
> StringBuffer sBuff = new StringBuffer();
> Iterator ki = attMap.keySet().iterator();
> while (ki.hasNext()) {
> String key = (String) ki.next();
> sBuff.append(key);
> List values = (List) attMap.get(key);
> for (Iterator vi = values.iterator(); vi.hasNext();) {
> String value = (String) vi.next();
> if (isText(value)) {
> sBuff.append(" \"" + value + "\"");
> } else {
> sBuff.append(" " + value);
> }
> }
> if (ki.hasNext()) {
> sBuff.append(";"); <---!!
> sBuff.append(" ");
> }
> }
> return sBuff.substring(0);
> }
> _______________________________________________
> biojava-dev mailing list
> biojava-dev at lists.open-bio.org
> http://lists.open-bio.org/mailman/listinfo/biojava-dev
>
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.2.2 (GNU/Linux)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org
iD8DBQFFiWPy4C5LeMEKA/QRAmJWAJ9jmAvPhQYF0YlJEYye7/XdPa7NhgCbBI5t
lImvTgNuqgd6/RukpFd4Pik=
=y7hf
-----END PGP SIGNATURE-----
More information about the biojava-dev
mailing list