/** * Create an instance of {@link NetworkAttachments } * */ public NetworkAttachments createNetworkAttachments() { return new NetworkAttachments(); }
@Override public V3NetworkAttachments adapt(NetworkAttachments from) { V3NetworkAttachments to = new V3NetworkAttachments(); if (from.isSetActions()) { to.setActions(adaptOut(from.getActions())); } if (from.isSetActive()) { to.setActive(from.getActive()); } if (from.isSetSize()) { to.setSize(from.getSize()); } if (from.isSetTotal()) { to.setTotal(from.getTotal()); } to.getNetworkAttachments().addAll(adaptOut(from.getNetworkAttachments())); return to; } }
@Override public NetworkAttachments adapt(V3NetworkAttachments from) { NetworkAttachments to = new NetworkAttachments(); if (from.isSetActions()) { to.setActions(adaptIn(from.getActions())); } if (from.isSetActive()) { to.setActive(from.getActive()); } if (from.isSetSize()) { to.setSize(from.getSize()); } if (from.isSetTotal()) { to.setTotal(from.getTotal()); } to.getNetworkAttachments().addAll(adaptIn(from.getNetworkAttachments())); return to; } }
private NetworkAttachments mapCollection(List<org.ovirt.engine.core.common.businessentities.network.NetworkAttachment> networkAttachments) { NetworkAttachments collection = new NetworkAttachments(); for (org.ovirt.engine.core.common.businessentities.network.NetworkAttachment networkAttachmentEntity : networkAttachments) { NetworkAttachment networkAttachmentModel = populate(map(networkAttachmentEntity), networkAttachmentEntity); collection.getNetworkAttachments().add(addLinks(networkAttachmentModel, getParentClass())); } return collection; } }
@Override protected List<org.ovirt.engine.api.model.NetworkAttachment> getCollection() { return collection.list().getNetworkAttachments(); }
.getNetworkAttachments()) { NetworkAttachment attachment = mapNetworkAttachment(attachmentsById, model); parameters.getNetworkAttachments().add(attachment); Entities.businessEntitiesById(parameters.getNetworkAttachments()); for (org.ovirt.engine.api.model.NetworkAttachment model : action.getSynchronizedNetworkAttachments() .getNetworkAttachments()) { if (model.isSetId()) { Guid networkAttachmentId = asGuid(model.getId()); .getNetworkAttachments()) { NetworkAttachment attachment = mapNetworkAttachment(attachmentsById, model); parameters.getRemovedNetworkAttachments().add(attachment.getId());