dto.setDefaultNetwork(defaultNetwork == null ? Boolean.FALSE : defaultNetwork);
dto.setUnmanaged(Boolean.FALSE);
dto.setType(NetworkType.EXTERNAL);
NetworkServiceType nst = networkServiceType.or(datacenter.defaultNetworkServiceType());
dto.addLink(new RESTLink("networkservicetype", nst.unwrap().getEditLink().getHref()));
ExternalNetwork network = new ExternalNetwork(context, dto);
network.datacenter = datacenter;
network.enterprise = enterprise;