Converts the object to a map representation.
@override Map<String, dynamic> toMap() { return { 'mainObjectRef': mainObjectRef ?? ref, 'duplicateRefs': duplicateRefs, }; }