package com.diagbot.service.impl;

import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import com.diagbot.dto.RelationDTO;
import com.diagbot.entity.Relation;
import com.diagbot.mapper.RelationMapper;
import com.diagbot.service.RelationService;
import com.diagbot.vo.AllRelationVo;
import com.diagbot.vo.RelationVo;
import com.diagbot.vo.TermVo;
import org.springframework.stereotype.Service;

import java.util.List;

/**
 * <p>
 *  服务实现类
 * </p>
 *
 * @author Weixuan Huang
 * @since 2019-01-31
 */
@Service
public class RelationServiceImpl extends ServiceImpl<RelationMapper, Relation> implements RelationService {
    @Override
    public IPage<RelationDTO> getAllRelation(AllRelationVo allrelationVo) {
        return baseMapper.getAllRelation(allrelationVo);
    }

    @Override
    public List<RelationDTO> getRelation(RelationDTO relationDTO) {
        return baseMapper.getRelation(relationDTO);
    }

    @Override
    public RelationDTO getRelationbyName(RelationVo relationVo) {
        return baseMapper.getRelationbyName(relationVo);
    }

    @Override
    public void truncateRelation() { baseMapper.truncateRelation(); }

    @Override
    public List<Relation> getLimboRelation() { return baseMapper.getLimboRelation(); }
}
