OASIS writer: Writing repetitions for edge-representation paths too

This commit is contained in:
Matthias Koefferlein 2022-12-08 20:36:03 +01:00
parent 2c94179589
commit 299cea51a5
1 changed files with 7 additions and 1 deletions

View File

@ -2964,7 +2964,7 @@ OASISWriter::write (const db::Path &path, db::properties_id_type prop_id, const
}
void
OASISWriter::write (const db::Edge &edge, db::properties_id_type prop_id, const db::Repetition & /*rep*/)
OASISWriter::write (const db::Edge &edge, db::properties_id_type prop_id, const db::Repetition &rep)
{
m_progress.set (mp_stream->pos ());
@ -2980,6 +2980,9 @@ OASISWriter::write (const db::Edge &edge, db::properties_id_type prop_id, const
if (mm_datatype != m_datatype) {
info |= 0x02;
}
if (! rep.is_singular ()) {
info |= 0x04;
}
if (mm_geometry_x != edge.p1 ().x ()) {
info |= 0x10;
}
@ -3030,6 +3033,9 @@ OASISWriter::write (const db::Edge &edge, db::properties_id_type prop_id, const
mm_geometry_y = edge.p1 ().y ();
write_coord (edge.p1 ().y ());
}
if (info & 0x04) {
write (rep);
}
if (prop_id != 0) {
write_props (prop_id);