/*
 * To change this license header, choose License Headers in Project Properties.
 * To change this template file, choose Tools | Templates
 * and open the template in the editor.
 */
package com.ifish.helper;

import com.ifish.bean.Tbl_Device;
import com.ifish.bean.Tbl_Device_Statistics;
import com.ifish.bean.Tbl_Device_User;
import com.ifish.bean.Tbl_Live_Room;
import com.ifish.bean.Tbl_User;

/**
 *
 * @author Administrator
 */
public interface RedisKeyHelperI {

    /**
     * 根据token获取tbl_user用户信息的redis缓存key键值
     *
     * @param token
     * @return
     */
    public String getTbl_UserRedisKeyByToken(String token);

    /**
     * 根据userId获取Tbl_User用户信息的Redis缓存key键值
     *
     * @param userId
     * @return
     */
    public String getTbl_UserRedisKeyByUserId(Integer userId);

    /**
     * 根据phoneNumber获取Tbl_User用户信息的Redis缓存key键值
     *
     * @param userId
     * @return
     */
    public String getTbl_UserRedisKeyByPhoneNumber(String phoneNumber);

    /**
     * 根据Email获取Tbl_User用户信息的Redis缓存key键值
     *
     * @param userId
     * @return
     */
    public String getTbl_UserRedisKeyByEmail(String email);

    /**
     * 根据mac地址获取Tbl_Device的redis缓存key键值
     *
     * @param macAddress
     * @return
     */
    public String getTbl_DeviceRedisKeyByMacAddress(String macAddress);

    /**
     * 根据摄像头Id获取Tbl_Device的redis缓存key键值
     *
     * @param macAddress
     * @return
     */
    public String getTbl_CameraRedisKeyByCameraId(String CameraId);

    /**
     * 根据Id获取Tbl_Device的redis缓存key键值
     *
     * @param macAddress
     * @return
     */
    public String getTbl_DeviceRedisKeyByDeviceId(Integer deviceId);

    /**
     * 根据mac地址获取Tbl_Device_Statistics的redis缓存key键值
     *
     * @param macAddress
     * @return
     */
    public String getTbl_Device_StatisticsRedisKeyByMacAddress(String macAddress);

    /**
     * 根据Id获取Tbl_Device_Statistics的redis缓存key键值
     *
     * @param macAddress
     * @return
     */
    public String getTbl_Device_StatisticsRedisKeyByDeviceId(Integer deviceId);

    /**
     * 根据设备ID和用户ID获取Tbl_Device_User的redis缓存key键值
     *
     * @param userId
     * @param deviceId
     * @return
     */
    public String getTbl_Device_UserRedisKeyByDeviceIdAndUserId(Integer userId, Integer deviceId);

    /**
     * 根据设备ID获取Tbl_Device_User(列表)的redis缓存key键值
     *
     * @param userId
     * @param deviceId
     * @return
     */
    public String getListTbl_Device_UserKeyByDeviceId(Integer deviceId);

    /**
     * 根据用户ID获取Tbl_Device_User(列表)的redis缓存key键值
     *
     * @param userId
     * @param deviceId
     * @return
     */
    public String getListTbl_Device_UserKeyByUserId(Integer userId);

    /**
     * 根据typeCode获取Tbl_HardWare_Type的redis缓存key键值
     *
     * @param typeCode
     * @return
     */
    public String getTbl_HardWare_TypeRedisKeyByTypeCode(String typeCode);

    /**
     * 根据brandCode获取Tbl_Vender_list的redis缓存key键值
     *
     * @param brandCode
     * @return
     */
    public String getTbl_Vender_ListRedisKeyByCode(String brandCode);

    /**
     * 根据直播间Id获取Tbl_Live_Room的redis缓存key键值
     *
     * @param roomId
     * @return
     */
    public String getTbl_Live_RoomRedisKeyByRoomId(Integer roomId);

    /**
     * 根据用户Id获取Tbl_Live_Room的redis缓存key键值
     *
     * @param roomId
     * @return
     */
    public String getTbl_Live_RoomRedisKeyByUserId(Integer User);

    /**
     * 根据分页和排序条件获取直播间列表缓存key键值
     *
     * @param first
     * @param pageSize
     * @param orders
     * @return
     */
    public String getListTbl_Live_Room_RedisKey(Integer first, Integer pageSize, String orders);

    /**
     * 获取所有开启直播间总数量的redis缓存key键值
     *
     * @return
     */
    public String getTbl_Live_Room_CountRedisKey();

    /**
     * 获取直播间评论列表的redis缓存key键值
     *
     * @param roomId
     * @return
     */
    public String getTbl_Live_Message(Integer firstResult, Integer pageSize, Integer roomId);

    /**
     * 根据pushId获取Tbl_push_list的redis缓存key键值
     *
     * @param pushId
     * @return
     */
    public String getTbl_Push_List_RedisByPushId(Integer pushId);

    /**
     * 根据MD5值获取redis缓存key键值
     *
     * @param md5
     * @return
     */
    public String getEmailRedisKey(String md5);

    /**
     * 删除redis中某个设备详情的缓存
     *
     * @param device
     * @return
     */
    public void deleteRedisByTbl_Device(Tbl_Device device);

    /**
     * 删除redis中某个设备统计信息Tbl_Device_Statistics的缓存
     *
     * @param device
     * @return
     */
    public void deleteRedisByTbl_Device_Statistics(Tbl_Device_Statistics device);

    /**
     * 删除redis中某个设备和用户关系Tbl_Device_User的缓存
     *
     * @param tbl_Device_User
     */
    public void deleteRedisByTbl_Device_User(Tbl_Device_User tbl_Device_User);

    /**
     * 删除redis中某个用户Tbl_User的缓存
     *
     * @param tbl_User
     */
    public void deleteRedisByTbl_User(Tbl_User tbl_User);

    /**
     * 删除redis中某个直播间Tbl_Live_Room的缓存
     *
     * @param live_Room
     */
    public void deleteRedisByTbl_Live_Room(Tbl_Live_Room live_Room);

    /**
     * 删除redis中有直播间总数缓存
     */
    public void deleteRedisByLiveRoomListCount();

}
