package cn.ftebox.service.impl;

import cn.ftebox.dao.BloggerDao;
import cn.ftebox.entity.Blogger;
import cn.ftebox.entity.Link;
import cn.ftebox.service.BloggerService;
import org.springframework.stereotype.Service;

import javax.annotation.Resource;
import java.util.List;
import java.util.Map;

@Service("bloggerService")
public class BloggerServiceImpl implements BloggerService {
    @Resource
    private BloggerDao bloggerDao;

    @Override
    public Blogger getByUserName(String userName) {
        return bloggerDao.getByUserName(userName);
    }

    @Override
    public Integer update(Blogger blogger) {
        return bloggerDao.update(blogger);
    }

    @Override
    public Blogger find() {
        return bloggerDao.find();
    }

    @Override
    public Integer insert(Blogger blogger) {
        return bloggerDao.insert(blogger);
    }

    @Override
    public List<Link> list(Map<String, Object> paramMap) {
        return bloggerDao.list(paramMap);
    }

    @Override
    public Long getTotal(Map<String, Object> paramMap) {
        return bloggerDao.getTotal(paramMap);
    }

    @Override
    public Integer delete(Integer id) {
        return bloggerDao.delete(id);
    }
}
