fromJson static method
Implementation
static Layer fromJson(Map json) {
switch (json['type']) {
case 'BackgroundLayer':
return BackgroundLayerData.fromJson(json);
case 'EmojiLayer':
return EmojiLayerData.fromJson(json);
case 'ImageLayer':
return ImageLayerData.fromJson(json);
case 'LinkLayer':
return LinkLayerData.fromJson(json);
case 'TextLayer':
return TextLayerData.fromJson(json);
case 'BackgroundBlurLayer':
return BackgroundBlurLayerData.fromJson(json);
default:
return Layer();
}
}