toJsonLd method

  1. @override
Map<String, dynamic> toJsonLd()
override

Serialize SchemaMusicAlbum to JSON-LD

Implementation

@override
Map<String, dynamic> toJsonLd() => removeEmpty({
      ...super.toJsonLd(),
      '@type': 'MusicAlbum',
      'albumProductionType': convertToJsonLd(
          albumProductionType, [SchemaMusicAlbumProductionType]),
      'albumRelease': convertToJsonLd(albumRelease, [SchemaMusicRelease]),
      'albumReleaseType':
          convertToJsonLd(albumReleaseType, [SchemaMusicAlbumReleaseType]),
      'byArtist': convertToJsonLd(byArtist, [SchemaMusicGroup, SchemaPerson]),
    });