本文整理汇总了Java中javax.jmdns.impl.tasks.resolver.ServiceInfoResolver类的典型用法代码示例。如果您正苦于以下问题:Java ServiceInfoResolver类的具体用法?Java ServiceInfoResolver怎么用?Java ServiceInfoResolver使用的例子?那么, 这里精选的类代码示例或许可以为您提供帮助。
ServiceInfoResolver类属于javax.jmdns.impl.tasks.resolver包,在下文中一共展示了ServiceInfoResolver类的2个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: resolveServiceInfo
import javax.jmdns.impl.tasks.resolver.ServiceInfoResolver; //导入依赖的package包/类
ServiceInfoImpl resolveServiceInfo(String type, String name, String subtype, boolean persistent)
{
String lotype = type.toLowerCase();
this.registerServiceType(lotype);
if (_serviceCollectors.putIfAbsent(lotype, new ServiceCollector(lotype)) == null)
{
this.addServiceListener(lotype, _serviceCollectors.get(lotype));
}
// Check if the answer is in the cache.
final ServiceInfoImpl info = this.getServiceInfoFromCache(type, name, subtype, persistent);
// We still run the resolver to do the dispatch but if the info is already there it will quit immediately
new ServiceInfoResolver(this, info).start(_timer);
return info;
}
示例2: startServiceInfoResolver
import javax.jmdns.impl.tasks.resolver.ServiceInfoResolver; //导入依赖的package包/类
@Override
public void startServiceInfoResolver(ServiceInfoImpl info) {
new ServiceInfoResolver(_jmDNSImpl, info).start(_timer);
}