本文整理汇总了Java中org.matmaul.freeboxos.upnpav.UPnPAVConfig类的典型用法代码示例。如果您正苦于以下问题:Java UPnPAVConfig类的具体用法?Java UPnPAVConfig怎么用?Java UPnPAVConfig使用的例子?那么, 这里精选的类代码示例或许可以为您提供帮助。
UPnPAVConfig类属于org.matmaul.freeboxos.upnpav包,在下文中一共展示了UPnPAVConfig类的2个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: fetchUPnPAVConfig
import org.matmaul.freeboxos.upnpav.UPnPAVConfig; //导入依赖的package包/类
private void fetchUPnPAVConfig() throws FreeboxException {
LanConfig lc = fbClient.getLanManager().getLanConfig();
String mode = lc.getMode();
if ((mode != null) && !mode.equalsIgnoreCase("bridge")) {
// Only when Freebox Revolution is not in bridge mode
UPnPAVConfig upnpAvConfiguration = fbClient.getUPnPAVManager().getConfig();
updateState(new ChannelUID(getThing().getUID(), UPNPAVSTATUS),
upnpAvConfiguration.getEnabled() ? OnOffType.ON : OnOffType.OFF);
}
}
示例2: setUPnPAVStatus
import org.matmaul.freeboxos.upnpav.UPnPAVConfig; //导入依赖的package包/类
private void setUPnPAVStatus(Command command) throws FreeboxException {
if (command != null) {
if (command instanceof OnOffType || command instanceof OpenClosedType || command instanceof UpDownType) {
UPnPAVConfig upnpAvConfiguration = new UPnPAVConfig();
upnpAvConfiguration.setEnabled(command.equals(OnOffType.ON) || command.equals(UpDownType.UP)
|| command.equals(OpenClosedType.OPEN));
fbClient.getUPnPAVManager().setConfig(upnpAvConfiguration);
fetchUPnPAVConfig();
}
}
}