gpt4 book ai didi

com.zsmartsystems.zigbee.app.discovery.ZigBeeDiscoveryExtension.startScheduler()方法的使用及代码示例

转载 作者:知者 更新时间:2024-03-15 14:09:31 27 4
gpt4 key购买 nike

本文整理了Java中com.zsmartsystems.zigbee.app.discovery.ZigBeeDiscoveryExtension.startScheduler()方法的一些代码示例,展示了ZigBeeDiscoveryExtension.startScheduler()的具体用法。这些代码示例主要来源于Github/Stackoverflow/Maven等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。ZigBeeDiscoveryExtension.startScheduler()方法的具体详情如下:
包路径:com.zsmartsystems.zigbee.app.discovery.ZigBeeDiscoveryExtension
类名称:ZigBeeDiscoveryExtension
方法名:startScheduler

ZigBeeDiscoveryExtension.startScheduler介绍

暂无

代码示例

代码示例来源:origin: zsmartsystems/com.zsmartsystems.zigbee

/**
 * Performs an immediate refresh of the network. Subsequent updates are performed at the current update rate, and
 * the timer is restarted from the time of calling this method.
 */
public void refresh() {
  logger.debug("DISCOVERY Extension: Start mesh update task with interval of {} seconds", updatePeriod);
  // Delay the start slightly to allow any further processing to complete.
  // Also allows successive responses to filter through without retriggering an update.
  startScheduler(10);
}

代码示例来源:origin: zsmartsystems/com.zsmartsystems.zigbee

/**
 * Sets the update period for the mesh update service. This is the number of seconds between
 * subsequent mesh updates. Setting the period to 0 will disable mesh updates.
 *
 * @param updatePeriod number of seconds between mesh updates. Setting to 0 will stop updates.
 */
public void setUpdatePeriod(final int updatePeriod) {
  this.updatePeriod = updatePeriod;
  if (!extensionStarted) {
    return;
  }
  logger.debug("DISCOVERY Extension: Set mesh update interval to {} seconds", updatePeriod);
  if (updatePeriod == 0) {
    stopScheduler();
    return;
  }
  startScheduler(updatePeriod);
}

代码示例来源:origin: zsmartsystems/com.zsmartsystems.zigbee

@Override
public ZigBeeStatus extensionStartup() {
  logger.debug("DISCOVERY Extension: Startup");
  networkManager.addNetworkNodeListener(this);
  networkManager.addCommandListener(this);
  networkDiscoverer = new ZigBeeNetworkDiscoverer(networkManager);
  networkDiscoverer.startup();
  if (updatePeriod != 0) {
    startScheduler(10);
  }
  extensionStarted = true;
  return ZigBeeStatus.SUCCESS;
}

代码示例来源:origin: zsmartsystems/com.zsmartsystems.zigbee

Mockito.doNothing().when(extension).startDiscovery(node);
Mockito.doNothing().when(extension).stopDiscovery(node);
Mockito.doNothing().when(extension).startScheduler(ArgumentMatchers.any(int.class));
Mockito.verify(extension, Mockito.times(1)).startScheduler(1);
assertEquals(1, extension.getUpdatePeriod());

27 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com