fromJson static method

SectionPagination? fromJson(
  1. Map<String, dynamic>? json
)
override

Returns a new SectionPagination instance and imports its values from json if it's non-null, null if json is null.

Implementation

static SectionPagination? fromJson(Map<String, dynamic>? json) {
  if (json == null) {
    return null;
  }

  return SectionPagination(
    limit: json[r'limit'],
    page: json[r'page'],
    pages: json[r'pages'],
    total: json[r'total'],
    links: PaginationLinks.fromJson(json[r'_links']),
    embedded: SectionCollection.fromJson(json[r'_embedded']),
  );
}