GqlQuery.fromJson constructor

GqlQuery.fromJson(
  1. Map json_
)

Implementation

GqlQuery.fromJson(core.Map json_)
    : this(
        allowLiterals: json_.containsKey('allowLiterals')
            ? json_['allowLiterals'] as core.bool
            : null,
        namedBindings: json_.containsKey('namedBindings')
            ? (json_['namedBindings'] as core.Map<core.String, core.dynamic>)
                .map(
                (key, value) => core.MapEntry(
                  key,
                  GqlQueryParameter.fromJson(
                      value as core.Map<core.String, core.dynamic>),
                ),
              )
            : null,
        positionalBindings: json_.containsKey('positionalBindings')
            ? (json_['positionalBindings'] as core.List)
                .map((value) => GqlQueryParameter.fromJson(
                    value as core.Map<core.String, core.dynamic>))
                .toList()
            : null,
        queryString: json_.containsKey('queryString')
            ? json_['queryString'] as core.String
            : null,
      );