当前位置: 首页>>代码示例>>Java>>正文


Java SSDPDiscoveryProvider类代码示例

本文整理汇总了Java中com.connectsdk.discovery.provider.SSDPDiscoveryProvider的典型用法代码示例。如果您正苦于以下问题:Java SSDPDiscoveryProvider类的具体用法?Java SSDPDiscoveryProvider怎么用?Java SSDPDiscoveryProvider使用的例子?那么, 这里精选的类代码示例或许可以为您提供帮助。


SSDPDiscoveryProvider类属于com.connectsdk.discovery.provider包,在下文中一共展示了SSDPDiscoveryProvider类的5个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。

示例1: testUnregisterDeviceServiceWithWrongArguments

import com.connectsdk.discovery.provider.SSDPDiscoveryProvider; //导入依赖的package包/类
@Test
public void testUnregisterDeviceServiceWithWrongArguments() {
    discovery.deviceClasses.put("service", DIALService.class);
    Assert.assertEquals(1, discovery.deviceClasses.size());
    
    discovery.unregisterDeviceService(Objects.class, Object.class);
    Assert.assertEquals(1, discovery.deviceClasses.size());
    
    discovery.unregisterDeviceService(DLNAService.class, SSDPDiscoveryProvider.class);
    Assert.assertEquals(1, discovery.deviceClasses.size());

    discovery.unregisterDeviceService(DIALService.class, SSDPDiscoveryProvider.class);
    Assert.assertEquals(1, discovery.deviceClasses.size());
}
 
开发者ID:david-fenton,项目名称:Connect-SDK-Cordova-Plugin,代码行数:15,代码来源:DiscoveryManagerTest.java

示例2: testUnregisterDeviceServiceWithWrongProvider

import com.connectsdk.discovery.provider.SSDPDiscoveryProvider; //导入依赖的package包/类
@Test
public void testUnregisterDeviceServiceWithWrongProvider() {
    discovery.discoveryProviders.add(new SSDPDiscoveryProvider(Robolectric.application));
    discovery.deviceClasses.put(DIALService.ID, DIALService.class);
    Assert.assertEquals(1, discovery.discoveryProviders.size());
    Assert.assertEquals(1, discovery.deviceClasses.size());

    discovery.unregisterDeviceService(DIALService.class, ZeroconfDiscoveryProvider.class);
    Assert.assertEquals(1, discovery.deviceClasses.size());
    Assert.assertEquals(1, discovery.discoveryProviders.size());
}
 
开发者ID:david-fenton,项目名称:Connect-SDK-Cordova-Plugin,代码行数:12,代码来源:DiscoveryManagerTest.java

示例3: testUnregisterDeviceServiceWithWrongServiceID

import com.connectsdk.discovery.provider.SSDPDiscoveryProvider; //导入依赖的package包/类
@Test
public void testUnregisterDeviceServiceWithWrongServiceID() {
    discovery.discoveryProviders.add(new SSDPDiscoveryProvider(Robolectric.application));
    discovery.deviceClasses.put(DLNAService.ID, DIALService.class);
    Assert.assertEquals(1, discovery.discoveryProviders.size());
    Assert.assertEquals(1, discovery.deviceClasses.size());

    discovery.unregisterDeviceService(DIALService.class, SSDPDiscoveryProvider.class);
    Assert.assertEquals(1, discovery.deviceClasses.size());
    Assert.assertEquals(1, discovery.discoveryProviders.size());
}
 
开发者ID:david-fenton,项目名称:Connect-SDK-Cordova-Plugin,代码行数:12,代码来源:DiscoveryManagerTest.java

示例4: testUnregisterDeviceService

import com.connectsdk.discovery.provider.SSDPDiscoveryProvider; //导入依赖的package包/类
@Test
public void testUnregisterDeviceService() {
    discovery.discoveryProviders.add(new SSDPDiscoveryProvider(Robolectric.application));
    discovery.deviceClasses.put(DIALService.ID, DIALService.class);
    Assert.assertEquals(1, discovery.discoveryProviders.size());
    Assert.assertEquals(1, discovery.deviceClasses.size());

    discovery.unregisterDeviceService(DIALService.class, SSDPDiscoveryProvider.class);
    Assert.assertEquals(0, discovery.deviceClasses.size());
    Assert.assertEquals(0, discovery.discoveryProviders.size());
}
 
开发者ID:david-fenton,项目名称:Connect-SDK-Cordova-Plugin,代码行数:12,代码来源:DiscoveryManagerTest.java

示例5: testRegisterDeviceService

import com.connectsdk.discovery.provider.SSDPDiscoveryProvider; //导入依赖的package包/类
@Test
public void testRegisterDeviceService() {
    Assert.assertEquals(0, discovery.discoveryProviders.size());
    Assert.assertEquals(0, discovery.deviceClasses.size());
    
    discovery.registerDeviceService(DIALService.class, SSDPDiscoveryProvider.class);
    Assert.assertEquals(1, discovery.discoveryProviders.size());
    Assert.assertEquals(1, discovery.deviceClasses.size());
}
 
开发者ID:david-fenton,项目名称:Connect-SDK-Cordova-Plugin,代码行数:10,代码来源:DiscoveryManagerTest.java


注:本文中的com.connectsdk.discovery.provider.SSDPDiscoveryProvider类示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。