JsonNetworkImage constructor
JsonNetworkImage({
- Map<
String, dynamic> args = const {}, - JsonWidgetRegistry? registry,
- Alignment alignment = Alignment.center,
- int? cacheHeight,
- int? cacheWidth,
- Rect? centerSlice,
- Color? color,
- BlendMode? colorBlendMode,
- Widget errorBuilder()?,
- bool excludeFromSemantics = false,
- FilterQuality filterQuality = FilterQuality.low,
- BoxFit? fit,
- Widget frameBuilder(
- BuildContext,
- Widget,
- int?,
- bool,
- bool gaplessPlayback = false,
- Map<
String, String> ? headers, - double? height,
- bool isAntiAlias = false,
- Widget loadingBuilder()?,
- bool matchTextDirection = false,
- double? opacity,
- ImageRepeat repeat = ImageRepeat.noRepeat,
- double scale = 1.0,
- String? semanticLabel,
- required String src,
- double? width,
Implementation
JsonNetworkImage({
Map<String, dynamic> args = const {},
JsonWidgetRegistry? registry,
this.alignment = Alignment.center,
this.cacheHeight,
this.cacheWidth,
this.centerSlice,
this.color,
this.colorBlendMode,
this.errorBuilder,
this.excludeFromSemantics = false,
this.filterQuality = FilterQuality.low,
this.fit,
this.frameBuilder,
this.gaplessPlayback = false,
this.headers,
this.height,
this.isAntiAlias = false,
this.loadingBuilder,
this.matchTextDirection = false,
this.opacity,
this.repeat = ImageRepeat.noRepeat,
this.scale = 1.0,
this.semanticLabel,
required this.src,
this.width,
}) : super(
jsonWidgetArgs: JsonNetworkImageBuilderModel.fromDynamic(
{
'alignment': alignment,
'cacheHeight': cacheHeight,
'cacheWidth': cacheWidth,
'centerSlice': centerSlice,
'color': color,
'colorBlendMode': colorBlendMode,
'errorBuilder': errorBuilder,
'excludeFromSemantics': excludeFromSemantics,
'filterQuality': filterQuality,
'fit': fit,
'frameBuilder': frameBuilder,
'gaplessPlayback': gaplessPlayback,
'headers': headers,
'height': height,
'isAntiAlias': isAntiAlias,
'loadingBuilder': loadingBuilder,
'matchTextDirection': matchTextDirection,
'opacity': opacity,
'repeat': repeat,
'scale': scale,
'semanticLabel': semanticLabel,
'src': src,
'width': width,
...args,
},
args: args,
registry: registry,
),
jsonWidgetBuilder: () => JsonNetworkImageBuilder(
args: JsonNetworkImageBuilderModel.fromDynamic(
{
'alignment': alignment,
'cacheHeight': cacheHeight,
'cacheWidth': cacheWidth,
'centerSlice': centerSlice,
'color': color,
'colorBlendMode': colorBlendMode,
'errorBuilder': errorBuilder,
'excludeFromSemantics': excludeFromSemantics,
'filterQuality': filterQuality,
'fit': fit,
'frameBuilder': frameBuilder,
'gaplessPlayback': gaplessPlayback,
'headers': headers,
'height': height,
'isAntiAlias': isAntiAlias,
'loadingBuilder': loadingBuilder,
'matchTextDirection': matchTextDirection,
'opacity': opacity,
'repeat': repeat,
'scale': scale,
'semanticLabel': semanticLabel,
'src': src,
'width': width,
...args,
},
args: args,
registry: registry,
),
),
jsonWidgetType: JsonNetworkImageBuilder.kType,
);