toJson method

Map<String, dynamic> toJson()

Implementation

Map<String, dynamic> toJson() => {
      'action': action,
      if (targetStableId != null) 'target_stable_id': targetStableId,
      if (targetIdentifier != null) 'target_identifier': targetIdentifier,
      if (targetText != null) 'target_text': targetText,
      if (targetRole != null) 'target_role': targetRole,
      if (bounds != null) 'bounds': bounds,
      if (kind != null) 'kind': kind,
      if (targetTokens != null) 'target_tokens': targetTokens,
      if (insideStableId != null) 'inside_stable_id': insideStableId,
      if (insideText != null) 'inside_text': insideText,
      if (insideRole != null) 'inside_role': insideRole,
      if (forbidText != null) 'forbid_text': forbidText,
      if (nthMatch != null) 'nth_match': nthMatch,
      if (params.isNotEmpty) 'params': params,
    };