package ink.wgink.pojo.dtos.role;

import ink.wgink.pojo.pos.RolePO;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;

import java.io.Serializable;
import java.util.List;

/**
 * @ClassName: RoleDTO
 * @Description: 角色
 * @Author: wenc
 * @Date: 2019/1/6 3:50 PM
 * @Version: 1.0
 **/
@ApiModel
public class RoleDTO extends RolePO {

    @ApiModelProperty(name = "subRoles", value = "子角色列表")
    private List<RoleDTO> subRoles;

    public List<RoleDTO> getSubRoles() {
        return subRoles;
    }

    public void setSubRoles(List<RoleDTO> subRoles) {
        this.subRoles = subRoles;
    }

    @Override
    public String toString() {
        final StringBuilder sb = new StringBuilder("{");
        sb.append("\"subRoles\":")
                .append(subRoles);
        sb.append('}');
        return sb.toString();
    }
}