补文件

This commit is contained in:
joylink_zhangsai 2021-08-05 14:05:50 +08:00
parent 0296d007ab
commit 8be3baaba6
4 changed files with 797 additions and 0 deletions

View File

@ -0,0 +1,12 @@
package club.joylink.rtss.dao;
import club.joylink.rtss.entity.DraftMapRouteOverrun;
import club.joylink.rtss.entity.DraftMapRouteOverrunExample;
import org.springframework.stereotype.Repository;
/**
* DraftMapRouteOverrunDAO继承基类
*/
@Repository
public interface DraftMapRouteOverrunDAO extends MyBatisBaseDao<DraftMapRouteOverrun, Long, DraftMapRouteOverrunExample> {
}

View File

@ -0,0 +1,95 @@
package club.joylink.rtss.entity;
import java.io.Serializable;
/**
* @author
*
*/
public class DraftMapRouteOverrun implements Serializable {
private Long id;
private String code;
private String sectionCode;
private String switchCode;
private static final long serialVersionUID = 1L;
public Long getId() {
return id;
}
public void setId(Long id) {
this.id = id;
}
public String getCode() {
return code;
}
public void setCode(String code) {
this.code = code;
}
public String getSectionCode() {
return sectionCode;
}
public void setSectionCode(String sectionCode) {
this.sectionCode = sectionCode;
}
public String getSwitchCode() {
return switchCode;
}
public void setSwitchCode(String switchCode) {
this.switchCode = switchCode;
}
@Override
public boolean equals(Object that) {
if (this == that) {
return true;
}
if (that == null) {
return false;
}
if (getClass() != that.getClass()) {
return false;
}
DraftMapRouteOverrun other = (DraftMapRouteOverrun) that;
return (this.getId() == null ? other.getId() == null : this.getId().equals(other.getId()))
&& (this.getCode() == null ? other.getCode() == null : this.getCode().equals(other.getCode()))
&& (this.getSectionCode() == null ? other.getSectionCode() == null : this.getSectionCode().equals(other.getSectionCode()))
&& (this.getSwitchCode() == null ? other.getSwitchCode() == null : this.getSwitchCode().equals(other.getSwitchCode()));
}
@Override
public int hashCode() {
final int prime = 31;
int result = 1;
result = prime * result + ((getId() == null) ? 0 : getId().hashCode());
result = prime * result + ((getCode() == null) ? 0 : getCode().hashCode());
result = prime * result + ((getSectionCode() == null) ? 0 : getSectionCode().hashCode());
result = prime * result + ((getSwitchCode() == null) ? 0 : getSwitchCode().hashCode());
return result;
}
@Override
public String toString() {
StringBuilder sb = new StringBuilder();
sb.append(getClass().getSimpleName());
sb.append(" [");
sb.append("Hash = ").append(hashCode());
sb.append(", id=").append(id);
sb.append(", code=").append(code);
sb.append(", sectionCode=").append(sectionCode);
sb.append(", switchCode=").append(switchCode);
sb.append(", serialVersionUID=").append(serialVersionUID);
sb.append("]");
return sb.toString();
}
}

View File

@ -0,0 +1,492 @@
package club.joylink.rtss.entity;
import java.util.ArrayList;
import java.util.List;
public class DraftMapRouteOverrunExample {
protected String orderByClause;
protected boolean distinct;
protected List<Criteria> oredCriteria;
private Integer limit;
private Long offset;
public DraftMapRouteOverrunExample() {
oredCriteria = new ArrayList<Criteria>();
}
public void setOrderByClause(String orderByClause) {
this.orderByClause = orderByClause;
}
public String getOrderByClause() {
return orderByClause;
}
public void setDistinct(boolean distinct) {
this.distinct = distinct;
}
public boolean isDistinct() {
return distinct;
}
public List<Criteria> getOredCriteria() {
return oredCriteria;
}
public void or(Criteria criteria) {
oredCriteria.add(criteria);
}
public Criteria or() {
Criteria criteria = createCriteriaInternal();
oredCriteria.add(criteria);
return criteria;
}
public Criteria createCriteria() {
Criteria criteria = createCriteriaInternal();
if (oredCriteria.size() == 0) {
oredCriteria.add(criteria);
}
return criteria;
}
protected Criteria createCriteriaInternal() {
Criteria criteria = new Criteria();
return criteria;
}
public void clear() {
oredCriteria.clear();
orderByClause = null;
distinct = false;
}
public void setLimit(Integer limit) {
this.limit = limit;
}
public Integer getLimit() {
return limit;
}
public void setOffset(Long offset) {
this.offset = offset;
}
public Long getOffset() {
return offset;
}
protected abstract static class GeneratedCriteria {
protected List<Criterion> criteria;
protected GeneratedCriteria() {
super();
criteria = new ArrayList<Criterion>();
}
public boolean isValid() {
return criteria.size() > 0;
}
public List<Criterion> getAllCriteria() {
return criteria;
}
public List<Criterion> getCriteria() {
return criteria;
}
protected void addCriterion(String condition) {
if (condition == null) {
throw new RuntimeException("Value for condition cannot be null");
}
criteria.add(new Criterion(condition));
}
protected void addCriterion(String condition, Object value, String property) {
if (value == null) {
throw new RuntimeException("Value for " + property + " cannot be null");
}
criteria.add(new Criterion(condition, value));
}
protected void addCriterion(String condition, Object value1, Object value2, String property) {
if (value1 == null || value2 == null) {
throw new RuntimeException("Between values for " + property + " cannot be null");
}
criteria.add(new Criterion(condition, value1, value2));
}
public Criteria andIdIsNull() {
addCriterion("id is null");
return (Criteria) this;
}
public Criteria andIdIsNotNull() {
addCriterion("id is not null");
return (Criteria) this;
}
public Criteria andIdEqualTo(Long value) {
addCriterion("id =", value, "id");
return (Criteria) this;
}
public Criteria andIdNotEqualTo(Long value) {
addCriterion("id <>", value, "id");
return (Criteria) this;
}
public Criteria andIdGreaterThan(Long value) {
addCriterion("id >", value, "id");
return (Criteria) this;
}
public Criteria andIdGreaterThanOrEqualTo(Long value) {
addCriterion("id >=", value, "id");
return (Criteria) this;
}
public Criteria andIdLessThan(Long value) {
addCriterion("id <", value, "id");
return (Criteria) this;
}
public Criteria andIdLessThanOrEqualTo(Long value) {
addCriterion("id <=", value, "id");
return (Criteria) this;
}
public Criteria andIdIn(List<Long> values) {
addCriterion("id in", values, "id");
return (Criteria) this;
}
public Criteria andIdNotIn(List<Long> values) {
addCriterion("id not in", values, "id");
return (Criteria) this;
}
public Criteria andIdBetween(Long value1, Long value2) {
addCriterion("id between", value1, value2, "id");
return (Criteria) this;
}
public Criteria andIdNotBetween(Long value1, Long value2) {
addCriterion("id not between", value1, value2, "id");
return (Criteria) this;
}
public Criteria andCodeIsNull() {
addCriterion("code is null");
return (Criteria) this;
}
public Criteria andCodeIsNotNull() {
addCriterion("code is not null");
return (Criteria) this;
}
public Criteria andCodeEqualTo(String value) {
addCriterion("code =", value, "code");
return (Criteria) this;
}
public Criteria andCodeNotEqualTo(String value) {
addCriterion("code <>", value, "code");
return (Criteria) this;
}
public Criteria andCodeGreaterThan(String value) {
addCriterion("code >", value, "code");
return (Criteria) this;
}
public Criteria andCodeGreaterThanOrEqualTo(String value) {
addCriterion("code >=", value, "code");
return (Criteria) this;
}
public Criteria andCodeLessThan(String value) {
addCriterion("code <", value, "code");
return (Criteria) this;
}
public Criteria andCodeLessThanOrEqualTo(String value) {
addCriterion("code <=", value, "code");
return (Criteria) this;
}
public Criteria andCodeLike(String value) {
addCriterion("code like", value, "code");
return (Criteria) this;
}
public Criteria andCodeNotLike(String value) {
addCriterion("code not like", value, "code");
return (Criteria) this;
}
public Criteria andCodeIn(List<String> values) {
addCriterion("code in", values, "code");
return (Criteria) this;
}
public Criteria andCodeNotIn(List<String> values) {
addCriterion("code not in", values, "code");
return (Criteria) this;
}
public Criteria andCodeBetween(String value1, String value2) {
addCriterion("code between", value1, value2, "code");
return (Criteria) this;
}
public Criteria andCodeNotBetween(String value1, String value2) {
addCriterion("code not between", value1, value2, "code");
return (Criteria) this;
}
public Criteria andSectionCodeIsNull() {
addCriterion("section_code is null");
return (Criteria) this;
}
public Criteria andSectionCodeIsNotNull() {
addCriterion("section_code is not null");
return (Criteria) this;
}
public Criteria andSectionCodeEqualTo(String value) {
addCriterion("section_code =", value, "sectionCode");
return (Criteria) this;
}
public Criteria andSectionCodeNotEqualTo(String value) {
addCriterion("section_code <>", value, "sectionCode");
return (Criteria) this;
}
public Criteria andSectionCodeGreaterThan(String value) {
addCriterion("section_code >", value, "sectionCode");
return (Criteria) this;
}
public Criteria andSectionCodeGreaterThanOrEqualTo(String value) {
addCriterion("section_code >=", value, "sectionCode");
return (Criteria) this;
}
public Criteria andSectionCodeLessThan(String value) {
addCriterion("section_code <", value, "sectionCode");
return (Criteria) this;
}
public Criteria andSectionCodeLessThanOrEqualTo(String value) {
addCriterion("section_code <=", value, "sectionCode");
return (Criteria) this;
}
public Criteria andSectionCodeLike(String value) {
addCriterion("section_code like", value, "sectionCode");
return (Criteria) this;
}
public Criteria andSectionCodeNotLike(String value) {
addCriterion("section_code not like", value, "sectionCode");
return (Criteria) this;
}
public Criteria andSectionCodeIn(List<String> values) {
addCriterion("section_code in", values, "sectionCode");
return (Criteria) this;
}
public Criteria andSectionCodeNotIn(List<String> values) {
addCriterion("section_code not in", values, "sectionCode");
return (Criteria) this;
}
public Criteria andSectionCodeBetween(String value1, String value2) {
addCriterion("section_code between", value1, value2, "sectionCode");
return (Criteria) this;
}
public Criteria andSectionCodeNotBetween(String value1, String value2) {
addCriterion("section_code not between", value1, value2, "sectionCode");
return (Criteria) this;
}
public Criteria andSwitchCodeIsNull() {
addCriterion("switch_code is null");
return (Criteria) this;
}
public Criteria andSwitchCodeIsNotNull() {
addCriterion("switch_code is not null");
return (Criteria) this;
}
public Criteria andSwitchCodeEqualTo(String value) {
addCriterion("switch_code =", value, "switchCode");
return (Criteria) this;
}
public Criteria andSwitchCodeNotEqualTo(String value) {
addCriterion("switch_code <>", value, "switchCode");
return (Criteria) this;
}
public Criteria andSwitchCodeGreaterThan(String value) {
addCriterion("switch_code >", value, "switchCode");
return (Criteria) this;
}
public Criteria andSwitchCodeGreaterThanOrEqualTo(String value) {
addCriterion("switch_code >=", value, "switchCode");
return (Criteria) this;
}
public Criteria andSwitchCodeLessThan(String value) {
addCriterion("switch_code <", value, "switchCode");
return (Criteria) this;
}
public Criteria andSwitchCodeLessThanOrEqualTo(String value) {
addCriterion("switch_code <=", value, "switchCode");
return (Criteria) this;
}
public Criteria andSwitchCodeLike(String value) {
addCriterion("switch_code like", value, "switchCode");
return (Criteria) this;
}
public Criteria andSwitchCodeNotLike(String value) {
addCriterion("switch_code not like", value, "switchCode");
return (Criteria) this;
}
public Criteria andSwitchCodeIn(List<String> values) {
addCriterion("switch_code in", values, "switchCode");
return (Criteria) this;
}
public Criteria andSwitchCodeNotIn(List<String> values) {
addCriterion("switch_code not in", values, "switchCode");
return (Criteria) this;
}
public Criteria andSwitchCodeBetween(String value1, String value2) {
addCriterion("switch_code between", value1, value2, "switchCode");
return (Criteria) this;
}
public Criteria andSwitchCodeNotBetween(String value1, String value2) {
addCriterion("switch_code not between", value1, value2, "switchCode");
return (Criteria) this;
}
}
/**
*/
public static class Criteria extends GeneratedCriteria {
protected Criteria() {
super();
}
}
public static class Criterion {
private String condition;
private Object value;
private Object secondValue;
private boolean noValue;
private boolean singleValue;
private boolean betweenValue;
private boolean listValue;
private String typeHandler;
public String getCondition() {
return condition;
}
public Object getValue() {
return value;
}
public Object getSecondValue() {
return secondValue;
}
public boolean isNoValue() {
return noValue;
}
public boolean isSingleValue() {
return singleValue;
}
public boolean isBetweenValue() {
return betweenValue;
}
public boolean isListValue() {
return listValue;
}
public String getTypeHandler() {
return typeHandler;
}
protected Criterion(String condition) {
super();
this.condition = condition;
this.typeHandler = null;
this.noValue = true;
}
protected Criterion(String condition, Object value, String typeHandler) {
super();
this.condition = condition;
this.value = value;
this.typeHandler = typeHandler;
if (value instanceof List<?>) {
this.listValue = true;
} else {
this.singleValue = true;
}
}
protected Criterion(String condition, Object value) {
this(condition, value, null);
}
protected Criterion(String condition, Object value, Object secondValue, String typeHandler) {
super();
this.condition = condition;
this.value = value;
this.secondValue = secondValue;
this.typeHandler = typeHandler;
this.betweenValue = true;
}
protected Criterion(String condition, Object value, Object secondValue) {
this(condition, value, secondValue, null);
}
}
}

View File

@ -0,0 +1,198 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper namespace="club.joylink.rtss.dao.DraftMapRouteOverrunDAO">
<resultMap id="BaseResultMap" type="club.joylink.rtss.entity.DraftMapRouteOverrun">
<id column="id" jdbcType="BIGINT" property="id" />
<result column="code" jdbcType="VARCHAR" property="code" />
<result column="section_code" jdbcType="VARCHAR" property="sectionCode" />
<result column="switch_code" jdbcType="VARCHAR" property="switchCode" />
</resultMap>
<sql id="Example_Where_Clause">
<where>
<foreach collection="oredCriteria" item="criteria" separator="or">
<if test="criteria.valid">
<trim prefix="(" prefixOverrides="and" suffix=")">
<foreach collection="criteria.criteria" item="criterion">
<choose>
<when test="criterion.noValue">
and ${criterion.condition}
</when>
<when test="criterion.singleValue">
and ${criterion.condition} #{criterion.value}
</when>
<when test="criterion.betweenValue">
and ${criterion.condition} #{criterion.value} and #{criterion.secondValue}
</when>
<when test="criterion.listValue">
and ${criterion.condition}
<foreach close=")" collection="criterion.value" item="listItem" open="(" separator=",">
#{listItem}
</foreach>
</when>
</choose>
</foreach>
</trim>
</if>
</foreach>
</where>
</sql>
<sql id="Update_By_Example_Where_Clause">
<where>
<foreach collection="example.oredCriteria" item="criteria" separator="or">
<if test="criteria.valid">
<trim prefix="(" prefixOverrides="and" suffix=")">
<foreach collection="criteria.criteria" item="criterion">
<choose>
<when test="criterion.noValue">
and ${criterion.condition}
</when>
<when test="criterion.singleValue">
and ${criterion.condition} #{criterion.value}
</when>
<when test="criterion.betweenValue">
and ${criterion.condition} #{criterion.value} and #{criterion.secondValue}
</when>
<when test="criterion.listValue">
and ${criterion.condition}
<foreach close=")" collection="criterion.value" item="listItem" open="(" separator=",">
#{listItem}
</foreach>
</when>
</choose>
</foreach>
</trim>
</if>
</foreach>
</where>
</sql>
<sql id="Base_Column_List">
id, code, section_code, switch_code
</sql>
<select id="selectByExample" parameterType="club.joylink.rtss.entity.DraftMapRouteOverrunExample" resultMap="BaseResultMap">
select
<if test="distinct">
distinct
</if>
<include refid="Base_Column_List" />
from draft_map_route_overrun
<if test="_parameter != null">
<include refid="Example_Where_Clause" />
</if>
<if test="orderByClause != null">
order by ${orderByClause}
</if>
<if test="limit != null">
<if test="offset != null">
limit ${offset}, ${limit}
</if>
<if test="offset == null">
limit ${limit}
</if>
</if>
</select>
<select id="selectByPrimaryKey" parameterType="java.lang.Long" resultMap="BaseResultMap">
select
<include refid="Base_Column_List" />
from draft_map_route_overrun
where id = #{id,jdbcType=BIGINT}
</select>
<delete id="deleteByPrimaryKey" parameterType="java.lang.Long">
delete from draft_map_route_overrun
where id = #{id,jdbcType=BIGINT}
</delete>
<delete id="deleteByExample" parameterType="club.joylink.rtss.entity.DraftMapRouteOverrunExample">
delete from draft_map_route_overrun
<if test="_parameter != null">
<include refid="Example_Where_Clause" />
</if>
</delete>
<insert id="insert" keyColumn="id" keyProperty="id" parameterType="club.joylink.rtss.entity.DraftMapRouteOverrun" useGeneratedKeys="true">
insert into draft_map_route_overrun (code, section_code, switch_code
)
values (#{code,jdbcType=VARCHAR}, #{sectionCode,jdbcType=VARCHAR}, #{switchCode,jdbcType=VARCHAR}
)
</insert>
<insert id="insertSelective" keyColumn="id" keyProperty="id" parameterType="club.joylink.rtss.entity.DraftMapRouteOverrun" useGeneratedKeys="true">
insert into draft_map_route_overrun
<trim prefix="(" suffix=")" suffixOverrides=",">
<if test="code != null">
code,
</if>
<if test="sectionCode != null">
section_code,
</if>
<if test="switchCode != null">
switch_code,
</if>
</trim>
<trim prefix="values (" suffix=")" suffixOverrides=",">
<if test="code != null">
#{code,jdbcType=VARCHAR},
</if>
<if test="sectionCode != null">
#{sectionCode,jdbcType=VARCHAR},
</if>
<if test="switchCode != null">
#{switchCode,jdbcType=VARCHAR},
</if>
</trim>
</insert>
<select id="countByExample" parameterType="club.joylink.rtss.entity.DraftMapRouteOverrunExample" resultType="java.lang.Long">
select count(*) from draft_map_route_overrun
<if test="_parameter != null">
<include refid="Example_Where_Clause" />
</if>
</select>
<update id="updateByExampleSelective" parameterType="map">
update draft_map_route_overrun
<set>
<if test="record.id != null">
id = #{record.id,jdbcType=BIGINT},
</if>
<if test="record.code != null">
code = #{record.code,jdbcType=VARCHAR},
</if>
<if test="record.sectionCode != null">
section_code = #{record.sectionCode,jdbcType=VARCHAR},
</if>
<if test="record.switchCode != null">
switch_code = #{record.switchCode,jdbcType=VARCHAR},
</if>
</set>
<if test="_parameter != null">
<include refid="Update_By_Example_Where_Clause" />
</if>
</update>
<update id="updateByExample" parameterType="map">
update draft_map_route_overrun
set id = #{record.id,jdbcType=BIGINT},
code = #{record.code,jdbcType=VARCHAR},
section_code = #{record.sectionCode,jdbcType=VARCHAR},
switch_code = #{record.switchCode,jdbcType=VARCHAR}
<if test="_parameter != null">
<include refid="Update_By_Example_Where_Clause" />
</if>
</update>
<update id="updateByPrimaryKeySelective" parameterType="club.joylink.rtss.entity.DraftMapRouteOverrun">
update draft_map_route_overrun
<set>
<if test="code != null">
code = #{code,jdbcType=VARCHAR},
</if>
<if test="sectionCode != null">
section_code = #{sectionCode,jdbcType=VARCHAR},
</if>
<if test="switchCode != null">
switch_code = #{switchCode,jdbcType=VARCHAR},
</if>
</set>
where id = #{id,jdbcType=BIGINT}
</update>
<update id="updateByPrimaryKey" parameterType="club.joylink.rtss.entity.DraftMapRouteOverrun">
update draft_map_route_overrun
set code = #{code,jdbcType=VARCHAR},
section_code = #{sectionCode,jdbcType=VARCHAR},
switch_code = #{switchCode,jdbcType=VARCHAR}
where id = #{id,jdbcType=BIGINT}
</update>
</mapper>