Method.fromJson constructor

Method.fromJson(
  1. Map json_
)

Implementation

Method.fromJson(core.Map json_)
    : this(
        name: json_.containsKey('name') ? json_['name'] as core.String : null,
        options: json_.containsKey('options')
            ? (json_['options'] as core.List)
                .map((value) => Option.fromJson(
                    value as core.Map<core.String, core.dynamic>))
                .toList()
            : null,
        requestStreaming: json_.containsKey('requestStreaming')
            ? json_['requestStreaming'] as core.bool
            : null,
        requestTypeUrl: json_.containsKey('requestTypeUrl')
            ? json_['requestTypeUrl'] as core.String
            : null,
        responseStreaming: json_.containsKey('responseStreaming')
            ? json_['responseStreaming'] as core.bool
            : null,
        responseTypeUrl: json_.containsKey('responseTypeUrl')
            ? json_['responseTypeUrl'] as core.String
            : null,
        syntax: json_.containsKey('syntax')
            ? json_['syntax'] as core.String
            : null,
      );