toJson method

  1. @override
Object toJson()
override

Convert the Part content to json format.

Implementation

@override
Object toJson() => {
      'functionCall': {
        'name': name,
        'args': args,
        if (id != null) 'id': id,
      }
    };