package cn.com.poc.example.convert;	

import cn.com.poc.example.model.BizExampleModel;
import cn.com.poc.example.entity.BizExampleEntity;
import cn.com.poc.example.dto.BizExampleDto;


public class BizExampleConvert {

    public static BizExampleEntity modelToEntity(BizExampleModel model){
        BizExampleEntity entity = new BizExampleEntity();
        entity.setBizExampleId(model.getBizExampleId());
        entity.setBizExampleType(model.getBizExampleType());
        entity.setBizExampleBusissesId(model.getBizExampleBusissesId());
        entity.setBizExampleIcon(model.getBizExampleIcon());
        entity.setBizExampleTitle(model.getBizExampleTitle());
        entity.setBizExampleFile(model.getBizExampleFile());
        entity.setBizExampleRemark(model.getBizExampleRemark());
        return entity;
    }

    public static BizExampleModel entityToModel(BizExampleEntity entity){
        BizExampleModel model = new BizExampleModel();
        model.setBizExampleId(entity.getBizExampleId());
        model.setBizExampleType(entity.getBizExampleType());
        model.setBizExampleBusissesId(entity.getBizExampleBusissesId());
        model.setBizExampleIcon(entity.getBizExampleIcon());
        model.setBizExampleTitle(entity.getBizExampleTitle());
        model.setBizExampleFile(entity.getBizExampleFile());
        model.setBizExampleRemark(entity.getBizExampleRemark());
        return model;
    }
    
    public static BizExampleDto entityToDto(BizExampleEntity entity){
        BizExampleDto dto = new BizExampleDto();
        dto.setBizExampleId(entity.getBizExampleId());
        dto.setBizExampleType(entity.getBizExampleType());
        dto.setBizExampleBusissesId(entity.getBizExampleBusissesId());
        dto.setBizExampleIcon(entity.getBizExampleIcon());
        dto.setBizExampleTitle(entity.getBizExampleTitle());
        dto.setBizExampleFile(entity.getBizExampleFile());
        dto.setBizExampleRemark(entity.getBizExampleRemark());
        return dto;
    }

    public static BizExampleEntity dtoToEntity(BizExampleDto dto){
        BizExampleEntity entity = new BizExampleEntity();
        entity.setBizExampleId(dto.getBizExampleId());
        entity.setBizExampleType(dto.getBizExampleType());
        entity.setBizExampleBusissesId(dto.getBizExampleBusissesId());
        entity.setBizExampleIcon(dto.getBizExampleIcon());
        entity.setBizExampleTitle(dto.getBizExampleTitle());
        entity.setBizExampleFile(dto.getBizExampleFile());
        entity.setBizExampleRemark(dto.getBizExampleRemark());
        return entity;
    }
}