Returns this object in JSON format.
Map<String, dynamic> toJson() => {'id': id, 'label': label, 'nodes': nodes, 'subgraphs': subgraphs};