package com.xindazhou.business.convert.community.topic;

import com.xindazhou.business.controller.admin.community.topic.vo.TopicRespVO;
import com.xindazhou.business.controller.admin.community.topic.vo.TopicSaveReqVO;
import com.xindazhou.business.dal.community.dataobject.topic.TopicDO;
import com.xindazhou.framework.common.pojo.PageResult;
import org.mapstruct.Mapper;
import org.mapstruct.factory.Mappers;

import java.util.List;

/**
 * 话题 Convert
 *
 * @author xindazhou
 */
@Mapper
public interface TopicConvert {

    TopicConvert INSTANCE = Mappers.getMapper(TopicConvert.class);

    TopicDO convert(TopicSaveReqVO bean);

    TopicRespVO convert(TopicDO bean);

    PageResult<TopicRespVO> convertPage(PageResult<TopicDO> page);

    List<TopicRespVO> convertList(List<TopicDO> list);

}

