toJson method

  1. @override
Map<String, Object> toJson()

Returns a JSON presentation of the object.

Implementation

@override
Map<String, Object> toJson() {
  var result = <String, Object>{};
  result['kind'] = kind.toJson();
  result['fileIndex'] = fileIndex;
  result['offset'] = offset;
  result['length'] = length;
  result['startLine'] = startLine;
  result['startColumn'] = startColumn;
  var codeOffset = this.codeOffset;
  if (codeOffset != null) {
    result['codeOffset'] = codeOffset;
  }
  var codeLength = this.codeLength;
  if (codeLength != null) {
    result['codeLength'] = codeLength;
  }
  return result;
}