@Test public void testGetPhysicalHostIdentifier() throws Exception { PhysicalHostKey physicalHostKey = mock(PhysicalHostKey.class); Class<DataBrokerAdapter> class1 = DataBrokerAdapter.class; Method method = class1.getDeclaredMethod("getPhysicalHostIdentifier", new Class[]{PhysicalHostKey.class}); method.setAccessible(true); Object object = method.invoke(dataBrokerAdapter, new Object[]{physicalHostKey = mock(PhysicalHostKey.class)}); Assert.assertTrue(object != null); }
private InstanceIdentifier<PhysicalHost> getPhysicalHostIdentifier(PhysicalHostKey physicalHostKey) { return InstanceIdentifier .builder(PhysicalNetwork.class) .child(PhysicalHosts.class) .child(PhysicalHost.class, physicalHostKey) .build(); }
DataBrokerAdapter { private InstanceIdentifier<PhysicalHost> getPhysicalHostIdentifier(PhysicalHostKey physicalHostKey) { return InstanceIdentifier .builder(PhysicalNetwork.class) .child(PhysicalHosts.class) .child(PhysicalHost.class, physicalHostKey) .build(); } }
DataBrokerAdapter { private InstanceIdentifier<PhysicalHost> getPhysicalHostIdentifier(PhysicalHostKey physicalHostKey) { return InstanceIdentifier .builder(PhysicalNetwork.class) .child(PhysicalHosts.class) .child(PhysicalHost.class, physicalHostKey) .build(); } DataBrokerAdapter(DataBroker dataBroker); }
DataBrokerAdapter { private InstanceIdentifier<PhysicalHost> getPhysicalHostIdentifier(PhysicalHostKey physicalHostKey) { return InstanceIdentifier .builder(PhysicalNetwork.class) .child(PhysicalHosts.class) .child(PhysicalHost.class, physicalHostKey) .build(); } DataBrokerAdapter(DataBroker dataBroker);  }
DataBrokerAdapter { private InstanceIdentifier<PhysicalHost> getPhysicalHostIdentifier(PhysicalHostKey physicalHostKey) { return InstanceIdentifier .builder(PhysicalNetwork.class) .child(PhysicalHosts.class) .child(PhysicalHost.class, physicalHostKey) .build(); } DataBrokerAdapter(DataBroker dataBroker);   }