MoviePersistenceServiceImpl.java 文件源码

java
阅读 39 收藏 0 点赞 0 评论 0

项目:REST-Web-Services 作者:
/**
 * {@inheritDoc}
 */
@Override
public void updateOtherTitle(
        @NotNull @Valid final OtherTitle otherTitle,
        @Min(1) final Long otherTitleId,
        @NotNull final MovieEntity movie
) throws ResourceConflictException {
    log.info("Called with otherTitle {}, otherTitleId {}, movie {}", otherTitle, otherTitleId, movie);

    this.existsOtherTile(movie.getOtherTitles()
            .stream()
            .filter(ot -> ot.getStatus() == DataStatus.ACCEPTED)
            .collect(Collectors.toList()), otherTitle);

    final MovieOtherTitleEntity movieOtherTitle = this.entityManager.find(MovieOtherTitleEntity.class, otherTitleId);
    movieOtherTitle.setTitle(otherTitle.getTitle());
    movieOtherTitle.setCountry(otherTitle.getCountry());
}
评论列表
文章目录


问题


面经


文章

微信
公众号

扫码关注公众号