Skip to content
Snippets Groups Projects
Commit eeefdb6d authored by tjc's avatar tjc
Browse files

split entries

git-svn-id: svn+ssh://svn.internal.sanger.ac.uk/repos/svn/pathsoft/artemis/trunk@9168 ee4ac58c-ac51-4696-9907-e4b3aa274f04
parent 0434bd22
No related branches found
No related tags found
No related merge requests found
...@@ -107,8 +107,13 @@ public class DatabaseDocument extends Document ...@@ -107,8 +107,13 @@ public class DatabaseDocument extends Document
private ByteBuffer gff_buff; private ByteBuffer gff_buff;
/** entries to split into */ /** entries to split into - each is given a name and the features within the entry */
private String[] types = { "repeat_region", "transcript" }; private String[][][] types =
{
{ {"repeats"} , {"repeat_region", "direct_repeat"} },
{ {"EST"} , {"EST_match", "match_part"} },
{ {"contig+gap"}, {"contig", "gap"}}
};
/** true if splitting the GFF into entries */ /** true if splitting the GFF into entries */
private boolean splitGFFEntry; private boolean splitGFFEntry;
...@@ -592,7 +597,7 @@ public class DatabaseDocument extends Document ...@@ -592,7 +597,7 @@ public class DatabaseDocument extends Document
if(gff_buffer[i].size() == 0) if(gff_buffer[i].size() == 0)
continue; continue;
String name = types[i-1]; String name = types[i-1][0][0];
new_docs[nentries] = new DatabaseDocument(location, pfield, id, schema, new_docs[nentries] = new DatabaseDocument(location, pfield, id, schema,
gff_buffer[i], name); gff_buffer[i], name);
...@@ -705,8 +710,9 @@ public class DatabaseDocument extends Document ...@@ -705,8 +710,9 @@ public class DatabaseDocument extends Document
this_buff = buffers[0]; this_buff = buffers[0];
for(int j = 0; j < types.length; j++) for(int j = 0; j < types.length; j++)
{ {
if(types[j].equals(typeName)) for(int k=0; k<types[j][1].length; k++)
this_buff = buffers[j+1]; if(types[j][1][k].equals(typeName))
this_buff = buffers[j+1];
} }
chadoToGFF(feat, srcFeature.getUniqueName(), chadoToGFF(feat, srcFeature.getUniqueName(),
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment