Documentation Index
Fetch the complete documentation index at: https://mintlify.com/juuaaann456/DMI-Practica06/llms.txt
Use this file to discover all available pages before exploring further.
Movie is the central data structure used by every layer of the app — providers, widgets, and repositories all pass Movie objects. It lives in the domain layer, which means it has no dependency on Flutter, Riverpod, or any external package.
Class definition
lib/domain/entities/movie.dart
Fields
Indicates whether the movie is restricted to adult audiences.
Absolute URL to the backdrop image (
w500 size). Built by MovieMapper from the raw path returned by the API. Defaults to a placeholder image URL when the API returns an empty string.List of TheMovieDB genre identifiers associated with the movie.
Unique TheMovieDB identifier for the movie.
ISO 639-1 language code of the movie’s original language (e.g.
"en", "es").Title of the movie in its original language.
Short plot summary. May be an empty string if the API did not provide one.
TheMovieDB popularity score. Higher values indicate more views and interactions on the platform.
Absolute URL to the poster image (
w500 size). Built by MovieMapper. Falls back to the string "no-poster" when the API returns an empty string.Theatrical release date. When the API returns a null or empty date string,
MovieMapper defaults this to DateTime(1900).Localised display title of the movie.
true if the entry is a video release rather than a theatrical film.Average user rating on TheMovieDB, on a scale of 0 to 10.
Total number of user votes that make up
voteAverage.Domain layer design
Movie is a plain Dart class — no json_serializable, no freezed, no Flutter imports. This is intentional:
- The domain layer stays portable and testable without a Flutter environment.
- All serialization logic lives in
MovieMovieDB.fromJson()in the infrastructure layer. - All API-to-domain transformation logic lives in
MovieMapper.movieDBToEntity().
Movie directly; they receive instances that have already been mapped from MovieMovieDB by the datasource layer.
If you add a new field to
Movie, you must also add it to MovieMovieDB, update MovieMovieDB.fromJson() / toJson(), and update MovieMapper.movieDBToEntity().