Search in sources :

Example 1 with VoltPonLinkConfig

use of org.onosproject.drivers.fujitsu.behaviour.VoltPonLinkConfig in project onos by opennetworkinglab.

the class VoltGetPonLinksCommand method doExecute.

@Override
protected void doExecute() {
    DriverService service = get(DriverService.class);
    deviceId = DeviceId.deviceId(uri);
    DriverHandler h = service.createHandler(deviceId);
    VoltPonLinkConfig volt = h.behaviour(VoltPonLinkConfig.class);
    String reply = volt.getPonLinks(target);
    if (reply != null) {
        print("%s", reply);
    } else {
        print("No reply from %s", deviceId.toString());
    }
}
Also used : VoltPonLinkConfig(org.onosproject.drivers.fujitsu.behaviour.VoltPonLinkConfig) DriverHandler(org.onosproject.net.driver.DriverHandler) DriverService(org.onosproject.net.driver.DriverService)

Example 2 with VoltPonLinkConfig

use of org.onosproject.drivers.fujitsu.behaviour.VoltPonLinkConfig in project onos by opennetworkinglab.

the class VoltSetPonLinkCommand method doExecute.

@Override
protected void doExecute() {
    DriverService service = get(DriverService.class);
    deviceId = DeviceId.deviceId(uri);
    DriverHandler h = service.createHandler(deviceId);
    VoltPonLinkConfig volt = h.behaviour(VoltPonLinkConfig.class);
    volt.setPonLink(target);
}
Also used : VoltPonLinkConfig(org.onosproject.drivers.fujitsu.behaviour.VoltPonLinkConfig) DriverHandler(org.onosproject.net.driver.DriverHandler) DriverService(org.onosproject.net.driver.DriverService)

Aggregations

VoltPonLinkConfig (org.onosproject.drivers.fujitsu.behaviour.VoltPonLinkConfig)2 DriverHandler (org.onosproject.net.driver.DriverHandler)2 DriverService (org.onosproject.net.driver.DriverService)2