Search in sources :

Example 1 with FlowResponseV2

use of org.openkilda.northbound.dto.v2.flows.FlowResponseV2 in project open-kilda by telstra.

the class FlowMapper method toFlowResponseV2.

/**
 * Map {@link FlowDto} into {@link FlowResponseV2}.
 */
public FlowResponseV2 toFlowResponseV2(FlowDto flowDto) {
    DetectConnectedDevicesDto connectedDevices = flowDto.getDetectConnectedDevices();
    FlowEndpointV2 source = generatedFlowSourceEndpointMap(flowDto);
    source.setDetectConnectedDevices(generatedFlowSourceEndpointConnectedDevicesMap(connectedDevices));
    FlowEndpointV2 destination = generatedFlowDestinationEndpointMap(flowDto);
    destination.setDetectConnectedDevices(generatedFlowDestinationEndpointConnectedDevicesMap(connectedDevices));
    FlowResponseV2 result = generatedMap(flowDto, source, destination);
    result.setSource(source);
    result.setDestination(destination);
    return result;
}
Also used : DetectConnectedDevicesDto(org.openkilda.messaging.model.DetectConnectedDevicesDto) FlowEndpointV2(org.openkilda.northbound.dto.v2.flows.FlowEndpointV2) FlowResponseV2(org.openkilda.northbound.dto.v2.flows.FlowResponseV2)

Aggregations

DetectConnectedDevicesDto (org.openkilda.messaging.model.DetectConnectedDevicesDto)1 FlowEndpointV2 (org.openkilda.northbound.dto.v2.flows.FlowEndpointV2)1 FlowResponseV2 (org.openkilda.northbound.dto.v2.flows.FlowResponseV2)1