package com.red.circle.other.infra.database.mongo.entity.live;

import com.fasterxml.jackson.databind.annotation.JsonSerialize;
import com.fasterxml.jackson.databind.ser.std.ToStringSerializer;
import java.io.Serial;
import java.io.Serializable;
import java.sql.Timestamp;
import lombok.AccessLevel;
import lombok.Data;
import lombok.experimental.Accessors;
import lombok.experimental.FieldDefaults;
import org.springframework.data.annotation.Id;
import org.springframework.data.mongodb.core.mapping.Document;

/**
 * 房间活跃统计.
 *
 * @author pengliang on 2022/3/24
 */
@Data
@Accessors(chain = true)
@Document("statistics_room_active")
@FieldDefaults(level = AccessLevel.PRIVATE)
public class StatisticsRoomActive implements Serializable {

  @Serial
  private static final long serialVersionUID = 1L;

  /**
   * 记录id.
   */
  @Id
  String id;

  /**
   * 房间Id.
   */
  @JsonSerialize(using = ToStringSerializer.class)
  Long roomId;

  /**
   * 房主ID.
   */
  @JsonSerialize(using = ToStringSerializer.class)
  Long userId;

  /**
   * 归属平台.
   */
  String sysOrigin;

  /**
   * 活跃指标.
   */
  RoomActiveIndex roomActiveIndex;

  /**
   * 创建时间.
   */
  Timestamp createTime;

  /**
   * 过期时间
   */
  Timestamp expiredTime;
}
