package com.YuyeTech.HeartRate.game.bluetoothinfo.service;

import com.YuyeTech.HeartRate.common.service.CommonService;
import com.YuyeTech.HeartRate.game.bluetoothinfo.projo.BluetoothInfo;
import com.YuyeTech.HeartRate.dto.BLToothDTO;
import com.YuyeTech.HeartRate.game.bluetoothinfo.vo.BluetoothInfoVo;
import org.springframework.data.domain.Page;
import org.springframework.data.domain.Pageable;

import java.util.List;

/**
 * @author:slambb
 * @date:2020/6/11
 */

public interface BluetoothInfoService extends CommonService<BluetoothInfoVo, BluetoothInfo, Integer> {

    BluetoothInfo findByMac(String mac);

    BluetoothInfo findByUserIdAndType(String userId, Integer type);

    BluetoothInfo findByMacAndType(String mac,Integer type);


    BluetoothInfo saveBluetoothInfo(BluetoothInfo bluetoothInfo);

    List<BluetoothInfo> addMoreBluetoothInfos(List<BluetoothInfo> bluetoothInfos);

    List<BLToothDTO> findAllByUserId(String userId);


    Page<BluetoothInfo> findAllBLEInfoByPageable(Pageable request);


    Page<BluetoothInfo> findAllBLEByPageableAndMac(Pageable request,String mac);

    String deleteBluetoothInfoById(Integer bleId);

    List<BluetoothInfo> findAllByIdentifier(String identifier);
}
