MovieCard class

A reusable movie card widget with cache status indicators.

Inheritance

Constructors

MovieCard.new({Key? key, required Movie movie, bool? fromCache, Duration? cacheAge, bool? cacheOnlyMode, VoidCallback? onTap, MovieCardStyle style = MovieCardStyle.poster, double? width, double? height, Widget? trailing, Widget? customSubtitle, FavoritesService? favoritesService, Widget? parentWidget})
Creates a movie card widget.
const
MovieCard.listItem({Key? key, required Movie movie, bool? fromCache, Duration? cacheAge, bool? cacheOnlyMode, VoidCallback? onTap, Widget? trailing, Widget? customSubtitle, FavoritesService? favoritesService, Widget? parentWidget})
Creates a list item-style movie card.
const
MovieCard.poster({Key? key, required Movie movie, bool? fromCache, Duration? cacheAge, bool? cacheOnlyMode, VoidCallback? onTap, double? width = 130, double? height, FavoritesService? favoritesService, Widget? parentWidget})
Creates a poster-style movie card.
const

Properties

cacheAge Duration?
Age of cached data (if applicable).
final
cacheOnlyMode bool?
Whether the app is in offline mode.
final
customSubtitle Widget?
Custom subtitle widget for list items (overrides default rating).
final
favoritesService FavoritesService?
The favorites service for quick actions (optional).
final
fromCache bool?
Whether this movie data came from cache.
final
hashCode int
The hash code for this object.
no setterinherited
height double?
Custom height for poster style.
final
key Key?
Controls how one widget replaces another widget in the tree.
finalinherited
movie Movie
The movie to display.
final
onTap VoidCallback?
Callback when the card is tapped.
final
parentWidget Widget?
The parent widget for navigation when sharing (optional).
final
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
style MovieCardStyle
Style of the movie card.
final
trailing Widget?
Additional trailing widget for list items.
final
width double?
Custom width for poster style.
final

Methods

createElement() StatefulElement
Creates a StatefulElement to manage this widget's location in the tree.
inherited
createState() State<MovieCard>
Creates the mutable state for this widget at a given location in the tree.
override
debugDescribeChildren() List<DiagnosticsNode>
Returns a list of DiagnosticsNode objects describing this node's children.
inherited
debugFillProperties(DiagnosticPropertiesBuilder properties) → void
Add additional properties associated with the node.
inherited
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toDiagnosticsNode({String? name, DiagnosticsTreeStyle? style}) DiagnosticsNode
Returns a debug representation of the object that is used by debugging tools and by DiagnosticsNode.toStringDeep.
inherited
toString({DiagnosticLevel minLevel = DiagnosticLevel.info}) String
A string representation of this object.
inherited
toStringDeep({String prefixLineOne = '', String? prefixOtherLines, DiagnosticLevel minLevel = DiagnosticLevel.debug, int wrapWidth = 65}) String
Returns a string representation of this node and its descendants.
inherited
toStringShallow({String joiner = ', ', DiagnosticLevel minLevel = DiagnosticLevel.debug}) String
Returns a one-line detailed description of the object.
inherited
toStringShort() String
A short, textual description of this widget.
inherited

Operators

operator ==(Object other) bool
The equality operator.
inherited