Commit 04ee12ed authored by Mathieu Giraud's avatar Mathieu Giraud
Browse files

core/segment.cpp: new json format

parent 5608bd5c
...@@ -50,25 +50,23 @@ string AlignBox::getSequence(string sequence) { ...@@ -50,25 +50,23 @@ string AlignBox::getSequence(string sequence) {
void AlignBox::addToJson(json &seg) { void AlignBox::addToJson(json &seg) {
seg[key] = ref_label; json j;
if (key == "5") j["name"] = ref_label;
{
seg[key+"end"] = end; if (key != "3") // no end information for J
seg[key+"del"] = del_right;
}
else if (key == "3")
{ {
seg[key+"del"] = del_left; j["end"] = end;
seg[key+"start"] = start; j["delRight"] = del_right;
} }
else
if (key != "5") // no start information for V
{ {
seg[key+"delLeft"] = del_left; j["start"] = start;
seg[key+"start"] = start; j["delLeft"] = del_left;
seg[key+"end"] = end;
seg[key+"delRight"] = del_right;
} }
seg[key] = j ;
} }
ostream &operator<<(ostream &out, const AlignBox &box) ostream &operator<<(ostream &out, const AlignBox &box)
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment