import org.opendaylight.transportpce.pce.service.PathComputationService;
import org.opendaylight.transportpce.pce.service.PathComputationServiceImpl;
import org.opendaylight.transportpce.renderer.RendererProvider;
-import org.opendaylight.transportpce.renderer.openroadminterface.OpenRoadmInterface121;
-import org.opendaylight.transportpce.renderer.openroadminterface.OpenRoadmInterface221;
-import org.opendaylight.transportpce.renderer.openroadminterface.OpenRoadmInterface710;
import org.opendaylight.transportpce.renderer.openroadminterface.OpenRoadmInterfaceFactory;
// Adding OTN interface
-import org.opendaylight.transportpce.renderer.openroadminterface.OpenRoadmOtnInterface221;
-import org.opendaylight.transportpce.renderer.openroadminterface.OpenRoadmOtnInterface710;
import org.opendaylight.transportpce.renderer.provisiondevice.DeviceRendererService;
import org.opendaylight.transportpce.renderer.provisiondevice.DeviceRendererServiceImpl;
import org.opendaylight.transportpce.renderer.provisiondevice.OtnDeviceRendererService;
olmProvider = new OlmProvider(lightyServices.getRpcProviderService(), olmPowerServiceRpc);
LOG.info("Creating renderer beans ...");
- OpenRoadmInterfaceFactory openRoadmInterfaceFactory = initOpenRoadmFactory(mappingUtils, openRoadmInterfaces,
- portMapping);
+ OpenRoadmInterfaceFactory openRoadmInterfaceFactory = initOpenRoadmFactory(mappingUtils, openRoadmInterfaces, portMapping);
DeviceRendererService deviceRendererService = new DeviceRendererServiceImpl(
lightyServices.getBindingDataBroker(), deviceTransactionManager, openRoadmInterfaceFactory,
openRoadmInterfaces, crossConnect, portMapping);
private OpenRoadmInterfaceFactory initOpenRoadmFactory(MappingUtils mappingUtils,
OpenRoadmInterfaces openRoadmInterfaces, PortMapping portMapping) {
- OpenRoadmInterface121 openRoadmInterface121 = new OpenRoadmInterface121(portMapping, openRoadmInterfaces);
- OpenRoadmInterface221 openRoadmInterface221 = new OpenRoadmInterface221(portMapping, openRoadmInterfaces);
- OpenRoadmInterface710 openRoadmInterface710 = new OpenRoadmInterface710(portMapping, openRoadmInterfaces);
- OpenRoadmOtnInterface221 openRoadmOtnInterface221 = new OpenRoadmOtnInterface221(portMapping,
- openRoadmInterfaces);
- OpenRoadmOtnInterface710 openRoadmOtnInterface710 = new OpenRoadmOtnInterface710(portMapping,
- openRoadmInterfaces);
- return new OpenRoadmInterfaceFactory(mappingUtils, openRoadmInterface121, openRoadmInterface221,
- openRoadmInterface710, openRoadmOtnInterface221, openRoadmOtnInterface710);
+ return new OpenRoadmInterfaceFactory(mappingUtils, portMapping, openRoadmInterfaces);
}
private PortMapping initPortMapping(LightyServices lightyServices) {
deviceTransactionManager, portMapping);
return new OpenRoadmInterfacesImpl(deviceTransactionManager, mappingUtils, openRoadmInterfacesImpl121,
openRoadmInterfacesImpl221, openRoadmInterfacesImpl710);
+
}
private CrossConnect initCrossConnect(MappingUtils mappingUtils) {
import org.opendaylight.transportpce.common.fixedflex.GridConstant;
import org.opendaylight.transportpce.common.fixedflex.SpectrumInformation;
import org.opendaylight.transportpce.common.mapping.MappingUtils;
+import org.opendaylight.transportpce.common.mapping.PortMapping;
import org.opendaylight.transportpce.common.openroadminterfaces.OpenRoadmInterfaceException;
+import org.opendaylight.transportpce.common.openroadminterfaces.OpenRoadmInterfaces;
import org.opendaylight.yang.gen.v1.http.org.opendaylight.transportpce.device.renderer.rev211004.az.api.info.AEndApiInfo;
import org.opendaylight.yang.gen.v1.http.org.opendaylight.transportpce.device.renderer.rev211004.az.api.info.ZEndApiInfo;
import org.opendaylight.yang.gen.v1.http.org.opendaylight.transportpce.portmapping.rev220922.mapping.Mapping;
private final OpenRoadmOtnInterface221 openRoadmOtnInterface221;
private final OpenRoadmOtnInterface710 openRoadmOtnInterface710;
- public OpenRoadmInterfaceFactory(MappingUtils mappingUtils, OpenRoadmInterface121 openRoadmInterface121,
- OpenRoadmInterface221 openRoadmInterface221, OpenRoadmInterface710 openRoadmInterface710,
- OpenRoadmOtnInterface221 openRoadmOTNInterface221, OpenRoadmOtnInterface710 openRoadmOtnInterface710) {
+ public OpenRoadmInterfaceFactory(MappingUtils mappingUtils, PortMapping portMapping,
+ OpenRoadmInterfaces openRoadmInterfaces) {
this.mappingUtils = mappingUtils;
- this.openRoadmInterface121 = openRoadmInterface121;
- this.openRoadmInterface221 = openRoadmInterface221;
- this.openRoadmInterface710 = openRoadmInterface710;
- this.openRoadmOtnInterface221 = openRoadmOTNInterface221;
- this.openRoadmOtnInterface710 = openRoadmOtnInterface710;
+ this.openRoadmInterface121 = new OpenRoadmInterface121(portMapping, openRoadmInterfaces);
+ this.openRoadmInterface221 = new OpenRoadmInterface221(portMapping, openRoadmInterfaces);
+ this.openRoadmInterface710 = new OpenRoadmInterface710(portMapping, openRoadmInterfaces);
+ this.openRoadmOtnInterface221 = new OpenRoadmOtnInterface221(portMapping, openRoadmInterfaces);
+ this.openRoadmOtnInterface710 = new OpenRoadmOtnInterface710(portMapping, openRoadmInterfaces);
}
public String createOpenRoadmEthInterface(String nodeId, String logicalConnPoint)
<reference id="networkModelService" interface="org.opendaylight.transportpce.networkmodel.service.NetworkModelService"/>
<reference id="olmService" interface="org.opendaylight.yang.gen.v1.http.org.opendaylight.transportpce.olm.rev210618.TransportpceOlmService"/>
- <bean id="openRoadmInterface121"
- class="org.opendaylight.transportpce.renderer.openroadminterface.OpenRoadmInterface121">
- <argument ref="portMapping"/>
- <argument ref="openRoadmInterfaces"/>
- </bean>
-
- <bean id="openRoadmInterface221"
- class="org.opendaylight.transportpce.renderer.openroadminterface.OpenRoadmInterface221">
- <argument ref="portMapping"/>
- <argument ref="openRoadmInterfaces"/>
- </bean>
-
- <bean id="openRoadmInterface710"
- class="org.opendaylight.transportpce.renderer.openroadminterface.OpenRoadmInterface710">
- <argument ref="portMapping"/>
- <argument ref="openRoadmInterfaces"/>
- </bean>
-
- <bean id="openRoadmOtnInterface221"
- class="org.opendaylight.transportpce.renderer.openroadminterface.OpenRoadmOtnInterface221">
- <argument ref="portMapping"/>
- <argument ref="openRoadmInterfaces"/>
- </bean>
-
- <bean id="openRoadmOtnInterface710"
- class="org.opendaylight.transportpce.renderer.openroadminterface.OpenRoadmOtnInterface710">
- <argument ref="portMapping"/>
- <argument ref="openRoadmInterfaces"/>
- </bean>
-
<bean id="openRoadmInterfaceFactory"
class="org.opendaylight.transportpce.renderer.openroadminterface.OpenRoadmInterfaceFactory">
<argument ref="mappingUtils"/>
- <argument ref="openRoadmInterface121"/>
- <argument ref="openRoadmInterface221"/>
- <argument ref="openRoadmInterface710"/>
- <argument ref="openRoadmOtnInterface221"/>
- <argument ref="openRoadmOtnInterface710"/>
+ <argument ref="portMapping"/>
+ <argument ref="openRoadmInterfaces"/>
</bean>
<bean id="deviceRenderer" class="org.opendaylight.transportpce.renderer.provisiondevice.DeviceRendererServiceImpl" >
import org.opendaylight.transportpce.common.openroadminterfaces.OpenRoadmInterfacesImpl121;
import org.opendaylight.transportpce.common.openroadminterfaces.OpenRoadmInterfacesImpl221;
import org.opendaylight.transportpce.common.openroadminterfaces.OpenRoadmInterfacesImpl710;
-import org.opendaylight.transportpce.renderer.openroadminterface.OpenRoadmInterface121;
-import org.opendaylight.transportpce.renderer.openroadminterface.OpenRoadmInterface221;
-import org.opendaylight.transportpce.renderer.openroadminterface.OpenRoadmInterface710;
import org.opendaylight.transportpce.renderer.openroadminterface.OpenRoadmInterfaceFactory;
-import org.opendaylight.transportpce.renderer.openroadminterface.OpenRoadmOtnInterface221;
-import org.opendaylight.transportpce.renderer.openroadminterface.OpenRoadmOtnInterface710;
import org.opendaylight.transportpce.renderer.utils.CreateOtsOmsDataUtils;
import org.opendaylight.transportpce.renderer.utils.MountPointUtils;
import org.opendaylight.transportpce.test.AbstractTest;
this.openRoadmInterfaces = new OpenRoadmInterfacesImpl(deviceTransactionManager, mappingUtils,
openRoadmInterfacesImpl121, openRoadmInterfacesImpl221, openRoadmInterfacesImpl710);
this.openRoadmInterfaces = spy(this.openRoadmInterfaces);
- OpenRoadmInterface121 openRoadmInterface121 = new OpenRoadmInterface121(portMapping,openRoadmInterfaces);
- OpenRoadmInterface221 openRoadmInterface221 = new OpenRoadmInterface221(portMapping,openRoadmInterfaces);
- OpenRoadmInterface710 openRoadmInterface710 = new OpenRoadmInterface710(portMapping, openRoadmInterfaces);
- OpenRoadmOtnInterface221 openRoadmOTNInterface221 = new OpenRoadmOtnInterface221(portMapping,
- openRoadmInterfaces);
- OpenRoadmOtnInterface710 openRoadmOtnInterface710 = new OpenRoadmOtnInterface710(portMapping,
- openRoadmInterfaces);
- this.openRoadmInterfaceFactory = new OpenRoadmInterfaceFactory(this.mappingUtils,openRoadmInterface121,
- openRoadmInterface221, openRoadmInterface710, openRoadmOTNInterface221, openRoadmOtnInterface710);
+ this.openRoadmInterfaceFactory = new OpenRoadmInterfaceFactory(this.mappingUtils, portMapping,
+ openRoadmInterfaces);
this.crossConnectImpl121 = new CrossConnectImpl121(this.deviceTransactionManager);
this.crossConnectImpl221 = new CrossConnectImpl221(this.deviceTransactionManager);