io.github.apkcloud.devicedetector.parser.device.PortableMediaPlayer Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of DeviceDetector Show documentation
Show all versions of DeviceDetector Show documentation
通用设备检测库将解析任何UserAgent并检测浏览器、操作系统、使用的设备(桌面、平板、移动、电视、车载、游戏机等等)、品牌和型号。
package io.github.apkcloud.devicedetector.parser.device;
import io.github.apkcloud.devicedetector.parser.AbstractParser;
import java.util.Map;
/**
* 用于检测便携式媒体播放器的设备解析器
*/
public class PortableMediaPlayer extends AbstractDeviceParser {
protected String fixtureFile = "regexes/device/portable_media_player.yml";
protected String parserName = "portablemediaplayer";
@Override
public String getName() {
return parserName;
}
@Override
public Map parse() throws Exception {
if (AbstractParser.isNullOrEmpty(preMatchOverall(fixtureFile))) {
return null;
}
return super.parse(fixtureFile);
}
}