本文整理了Java中org.ovirt.engine.core.common.businessentities.network.Network.isVmNetwork()
方法的一些代码示例,展示了Network.isVmNetwork()
的具体用法。这些代码示例主要来源于Github
/Stackoverflow
/Maven
等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。Network.isVmNetwork()
方法的具体详情如下:
包路径:org.ovirt.engine.core.common.businessentities.network.Network
类名称:Network
方法名:isVmNetwork
暂无
代码示例来源:origin: oVirt/ovirt-engine
public boolean isVmNetwork() {
return network.isVmNetwork();
}
代码示例来源:origin: oVirt/ovirt-engine
/**
* filter networks which are not VM networks from the newtorkNames list
* @param networks
* logical networks
* @param networkNames
* target names to match non-VM networks upon
*/
public static List<String> filterNonVmNetworkNames(List<Network> networks, Set<String> networkNames) {
return networks.stream()
.filter(net -> !net.isVmNetwork() && networkNames.contains(net.getName()))
.map(Network::getName)
.collect(Collectors.toList());
}
代码示例来源:origin: oVirt/ovirt-engine
public boolean isVmNetwork() {
return getEntity().isVmNetwork();
}
代码示例来源:origin: oVirt/ovirt-engine
private boolean doesBondHaveVmNetworkAttached(NetworkInterfaceModel... networkInterfaceModels){
for (NetworkInterfaceModel networkInterfaceModel : networkInterfaceModels){
for (LogicalNetworkModel logicalNetwork : networkInterfaceModel.getItems()) {
if (logicalNetwork.getNetwork().isVmNetwork()) {
return true;
}
}
}
return false;
}
代码示例来源:origin: oVirt/ovirt-engine
@Override
protected void initIsVm() {
getIsVmNetwork().setEntity(getNetwork().isVmNetwork());
}
代码示例来源:origin: oVirt/ovirt-engine
public EditNetworkModel(Network network, SearchableListModel<?, ? extends Network> sourceListModel) {
super(network, sourceListModel);
originallyVmNetwork = network.isVmNetwork();
getDataCenters().setIsChangeable(false);
init();
initManagement();
}
代码示例来源:origin: oVirt/ovirt-engine
private ReportedConfiguration reporteEqualBridged() {
return new ReportedConfiguration(ReportedConfigurationType.BRIDGED,
iface.isBridged(),
network.isVmNetwork(),
true);
}
代码示例来源:origin: oVirt/ovirt-engine
if (network.getNetwork().isVmNetwork()) {
if (dst instanceof BondNetworkInterfaceModel) {
BondNetworkInterfaceModel bondModel = (BondNetworkInterfaceModel) dst;
代码示例来源:origin: oVirt/ovirt-engine
private void updateProperties() {
Network extendedNetwork = getEntity();
setName(extendedNetwork.getName());
setId(extendedNetwork.getId());
setDescription(extendedNetwork.getDescription());
setVmNetwork(extendedNetwork.isVmNetwork());
setVlan(extendedNetwork.getVlanId());
setMtu(extendedNetwork.getMtu());
setVdsmName(extendedNetwork.getVdsmName());
if (extendedNetwork.isExternal()) {
setExternalId(extendedNetwork.getProvidedBy().getExternalId());
} else {
setExternalId(null);
}
}
代码示例来源:origin: oVirt/ovirt-engine
result.add(ReportedConfigurationType.BRIDGED, iface.isBridged(), network.isVmNetwork());
result.add(ReportedConfigurationType.VLAN, iface.getVlanId(), network.getVlanId());
result.add(ReportedConfigurationType.SWITCH_TYPE,
代码示例来源:origin: oVirt/ovirt-engine
@Override
public String toString() {
return ToStringBuilder.forInstance(this)
.append("id", getId())
.append("description", getDescription())
.append("comment", getComment())
.append("vdsmName", getVdsmName())
.append("subnet", getSubnet())
.append("gateway", getGateway())
.append("type", getType())
.append("vlanId", getVlanId())
.append("stp", getStp())
.append("dataCenterId", getDataCenterId())
.append("mtu", getMtu())
.append("vmNetwork", isVmNetwork())
.append("cluster", getCluster())
.append("providedBy", getProvidedBy())
.append("label", getLabel())
.append("qosId", getQosId())
.append("dnsResolverConfiguration", dnsResolverConfiguration)
.build();
}
代码示例来源:origin: oVirt/ovirt-engine
if (!network.isVmNetwork()) {
validProperties.remove("bridge_opts"); //$NON-NLS-1$
代码示例来源:origin: oVirt/ovirt-engine
private static Network cloneNetwork(Network instance) {
Network obj = new Network();
obj.setAddr(instance.getAddr());
obj.setDescription(instance.getDescription());
obj.setComment(instance.getComment());
obj.setId(instance.getId());
obj.setName(instance.getName());
obj.setVdsmName(instance.getVdsmName());
obj.setSubnet(instance.getSubnet());
obj.setGateway(instance.getGateway());
obj.setType(instance.getType());
obj.setVlanId(instance.getVlanId());
obj.setStp(instance.getStp());
obj.setDataCenterId(instance.getDataCenterId());
obj.setMtu(instance.getMtu());
obj.setVmNetwork(instance.isVmNetwork());
if (instance.getCluster() !=null){
obj.setCluster(cloneNetworkCluster(instance.getCluster()));
}
if (instance.getProvidedBy() != null) {
obj.setProvidedBy(cloneProviderNetwork(instance.getProvidedBy()));
}
return obj;
}
代码示例来源:origin: oVirt/ovirt-engine
if (entity.isVmNetwork()) {
model.getUsages().getUsages().add(NetworkUsage.VM);
代码示例来源:origin: oVirt/ovirt-engine
@Override
protected MapSqlParameterSource createFullParametersMapper(Network network) {
return getCustomMapSqlParameterSource()
.addValue("addr", network.getAddr())
.addValue("description", network.getDescription())
.addValue("free_text_comment", network.getComment())
.addValue("id", network.getId())
.addValue("name", network.getName())
.addValue("vdsm_name", network.getVdsmName())
.addValue("subnet", network.getSubnet())
.addValue("gateway", network.getGateway())
.addValue("type", network.getType())
.addValue("vlan_id", network.getVlanId())
.addValue("stp", network.getStp())
.addValue("storage_pool_id", network.getDataCenterId())
.addValue("mtu", network.getMtu())
.addValue("vm_network", network.isVmNetwork())
.addValue("provider_network_provider_id",
network.getProvidedBy() == null ? null : network.getProvidedBy().getProviderId())
.addValue("provider_network_external_id",
network.getProvidedBy() == null ? null : network.getProvidedBy().getExternalId())
.addValue("provider_physical_network_id",
network.getProvidedBy() == null ? null : network.getProvidedBy().getPhysicalNetworkId())
.addValue("qos_id", network.getQosId())
.addValue("label", network.getLabel())
.addValue("dns_resolver_configuration_id", getDnsResolverConfigurationId(network));
}
内容来源于网络,如有侵权,请联系作者删除!