class SDNCUnassignTasks extends AbstractSDNCTask {

    public void unassignNetwork(BuildingBlockExecution execution) throws Exception {
        try {
            GeneralBuildingBlock gBBInput = execution.getGeneralBuildingBlock();
            L3Network network = extractPojosForBB.extractByKey(execution, ResourceKey.NETWORK_ID);
            ServiceInstance serviceInstance =
                    extractPojosForBB.extractByKey(execution, ResourceKey.SERVICE_INSTANCE_ID);
            Customer customer = gBBInput.getCustomer();
            RequestContext requestContext = gBBInput.getRequestContext();
            CloudRegion cloudRegion = gBBInput.getCloudRegion();
            String cloudRegionSdnc = execution.getVariable("cloudRegionSdnc");
            cloudRegion.setLcpCloudRegionId(cloudRegionSdnc);
            GenericResourceApiNetworkOperationInformation req = sdncNetworkResources.unassignNetwork(network,
                    serviceInstance, customer, requestContext, cloudRegion);
            SDNCRequest sdncRequest = new SDNCRequest();
            sdncRequest.setSDNCPayload(req);
            sdncRequest.setTopology(SDNCTopology.NETWORK);
            execution.setVariable(SDNC_REQUEST, sdncRequest);
        } catch (Exception ex) {
            logger.error("Exception occurred in SDNCUnassignTasks unassignNetwork", ex);
            exceptionUtil.buildAndThrowWorkflowException(execution, 7000, ex);
        }
    }

}