Search in sources :

Example 16 with Song

use of org.mapstruct.ap.test.constructor.nestedsource.source.Song in project mapstruct by mapstruct.

the class ChartEntryToArtistImpl method chartSongPositions.

private List<Integer> chartSongPositions(Chart chart) {
    if (chart == null) {
        return null;
    }
    Song song = chart.getSong();
    if (song == null) {
        return null;
    }
    List<Integer> positions = song.getPositions();
    if (positions == null) {
        return null;
    }
    return positions;
}
Also used : Song(org.mapstruct.ap.test.constructor.nestedsource.source.Song)

Aggregations

Song (org.mapstruct.ap.test.constructor.nestedsource.source.Song)16 ProcessorTest (org.mapstruct.ap.testutil.ProcessorTest)8 WithClasses (org.mapstruct.ap.testutil.WithClasses)8 Artist (org.mapstruct.ap.test.constructor.nestedsource.source.Artist)7 ChartEntry (org.mapstruct.ap.test.constructor.nestedsource._target.ChartEntry)5 Label (org.mapstruct.ap.test.constructor.nestedsource.source.Label)5 Studio (org.mapstruct.ap.test.constructor.nestedsource.source.Studio)5 BaseChartEntry (org.mapstruct.ap.test.constructor.nestedsource._target.BaseChartEntry)3 Chart (org.mapstruct.ap.test.constructor.nestedsource.source.Chart)2 ChartEntryComposed (org.mapstruct.ap.test.constructor.nestedsource._target.ChartEntryComposed)1 ChartEntryLabel (org.mapstruct.ap.test.constructor.nestedsource._target.ChartEntryLabel)1 ChartEntryWithBase (org.mapstruct.ap.test.constructor.nestedsource._target.ChartEntryWithBase)1 ChartEntryWithMapping (org.mapstruct.ap.test.constructor.nestedsource._target.ChartEntryWithMapping)1