Proto2DescriptorProto.fromJson constructor

Proto2DescriptorProto.fromJson(
  1. Map json_
)

Implementation

Proto2DescriptorProto.fromJson(core.Map json_)
    : this(
        enumType: json_.containsKey('enumType')
            ? (json_['enumType'] as core.List)
                .map((value) => Proto2EnumDescriptorProto.fromJson(
                    value as core.Map<core.String, core.dynamic>))
                .toList()
            : null,
        field: json_.containsKey('field')
            ? (json_['field'] as core.List)
                .map((value) => Proto2FieldDescriptorProto.fromJson(
                    value as core.Map<core.String, core.dynamic>))
                .toList()
            : null,
        name: json_.containsKey('name') ? json_['name'] as core.String : null,
        nestedType: json_.containsKey('nestedType')
            ? (json_['nestedType'] as core.List)
                .map((value) => Proto2DescriptorProto.fromJson(
                    value as core.Map<core.String, core.dynamic>))
                .toList()
            : null,
        oneofDecl: json_.containsKey('oneofDecl')
            ? (json_['oneofDecl'] as core.List)
                .map((value) => Proto2OneofDescriptorProto.fromJson(
                    value as core.Map<core.String, core.dynamic>))
                .toList()
            : null,
      );