use of org.ovirt.engine.api.v3.types.V3Bonding in project ovirt-engine by oVirt.
the class V3BondingInAdapter method adapt.
@Override
public Bonding adapt(V3Bonding from) {
Bonding to = new Bonding();
if (from.isSetOptions()) {
to.setOptions(new Options());
to.getOptions().getOptions().addAll(adaptIn(from.getOptions().getOptions()));
}
if (from.isSetSlaves()) {
to.setSlaves(new HostNics());
to.getSlaves().getHostNics().addAll(adaptIn(from.getSlaves().getSlaves()));
}
return to;
}
use of org.ovirt.engine.api.v3.types.V3Bonding in project ovirt-engine by oVirt.
the class V3BondingOutAdapter method adapt.
@Override
public V3Bonding adapt(Bonding from) {
V3Bonding to = new V3Bonding();
if (from.isSetOptions()) {
to.setOptions(new V3Options());
to.getOptions().getOptions().addAll(adaptOut(from.getOptions().getOptions()));
}
if (from.isSetSlaves()) {
to.setSlaves(new V3Slaves());
to.getSlaves().getSlaves().addAll(adaptOut(from.getSlaves().getHostNics()));
}
return to;
}
Aggregations