package com.zanxiang.game.module.mybatis.entity;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import lombok.*;

import java.io.Serializable;
import java.time.LocalDateTime;

/**
 * @author : lingfeng
 * @time : 2022-06-06
 * @description : 玩家客户端登录token表
 */
@Data
@NoArgsConstructor
@AllArgsConstructor
@ToString
@Builder
@TableName("t_user_token")
public class UserToken implements Serializable {

    private static final long serialVersionUID = 1L;

    /**
     * id
     */
    @TableId(value = "id", type = IdType.AUTO)
    private Long id;

    /**
     * 玩家id
     */
    private Long userId;

    /**
     * 过期时间
     */
    private Long expireTime;

    /**
     * token
     */
    private String token;

    /**
     * 设备类型;mobile,android,iphone,ipad,web,pc,mac,wxapp
     */
    private Integer deviceType;

    /**
     * 创建时间
     */
    private LocalDateTime createTime;

    /**
     * 更新时间
     */
    private LocalDateTime updateTime;
}