SimpleListWrapperApplicationRole.fromJson constructor

SimpleListWrapperApplicationRole.fromJson(
  1. Map<String, Object?> json
)

Implementation

factory SimpleListWrapperApplicationRole.fromJson(Map<String, Object?> json) {
  return SimpleListWrapperApplicationRole(
    callback: json[r'callback'] != null
        ? ListWrapperCallbackApplicationRole.fromJson(
            json[r'callback']! as Map<String, Object?>)
        : null,
    items: (json[r'items'] as List<Object?>?)
            ?.map((i) => ApplicationRole.fromJson(
                i as Map<String, Object?>? ?? const {}))
            .toList() ??
        [],
    maxResults: (json[r'max-results'] as num?)?.toInt(),
    pagingCallback: json[r'pagingCallback'] != null
        ? ListWrapperCallbackApplicationRole.fromJson(
            json[r'pagingCallback']! as Map<String, Object?>)
        : null,
    size: (json[r'size'] as num?)?.toInt(),
  );
}