private UpdatedGroupImpl(UpdatedGroupBuilder base) { this._buckets = base.getBuckets(); this._containerName = base.getContainerName(); this._groupId = base.getGroupId(); this._groupName = base.getGroupName(); this._groupType = base.getGroupType(); this._barrier = base.isBarrier(); switch (base.augmentation.size()) { case 0: this.augmentation = Collections.emptyMap(); break; case 1: final Map.Entry<java.lang.Class<? extends Augmentation<org.opendaylight.yang.gen.v1.urn.opendaylight.group.service.rev130918.group.update.UpdatedGroup>>, Augmentation<org.opendaylight.yang.gen.v1.urn.opendaylight.group.service.rev130918.group.update.UpdatedGroup>> e = base.augmentation.entrySet().iterator().next(); this.augmentation = Collections.<java.lang.Class<? extends Augmentation<org.opendaylight.yang.gen.v1.urn.opendaylight.group.service.rev130918.group.update.UpdatedGroup>>, Augmentation<org.opendaylight.yang.gen.v1.urn.opendaylight.group.service.rev130918.group.update.UpdatedGroup>>singletonMap(e.getKey(), e.getValue()); break; default : this.augmentation = new HashMap<>(base.augmentation); } }
public UpdatedGroupBuilder addAugmentation(java.lang.Class<? extends Augmentation<org.opendaylight.yang.gen.v1.urn.opendaylight.group.service.rev130918.group.update.UpdatedGroup>> augmentationType, Augmentation<org.opendaylight.yang.gen.v1.urn.opendaylight.group.service.rev130918.group.update.UpdatedGroup> augmentation) { if (augmentation == null) { return removeAugmentation(augmentationType); } if (!(this.augmentation instanceof HashMap)) { this.augmentation = new HashMap<>(); } this.augmentation.put(augmentationType, augmentation); return this; }
groupBuilder.setGroupRef(new GroupRef(identifier)); groupBuilder.setTransactionUri(new Uri(getNewTransactionId())); groupBuilder.setUpdatedGroup((new UpdatedGroupBuilder(updGroup)).build()); if (origGroup == null){ LOG.warn("updateGroup: orig group is null not setting it");
@Override public void update(final InstanceIdentifier<Group> identifier, final Group original, final Group update, final InstanceIdentifier<FlowCapableNode> nodeIdent) { final Group originalGroup = (original); final Group updatedGroup = (update); final UpdateGroupInputBuilder builder = new UpdateGroupInputBuilder(); builder.setNode(new NodeRef(nodeIdent.firstIdentifierOf(Node.class))); builder.setGroupRef(new GroupRef(identifier)); builder.setTransactionUri(new Uri(provider.getNewTransactionId())); builder.setUpdatedGroup((new UpdatedGroupBuilder(updatedGroup)).build()); builder.setOriginalGroup((new OriginalGroupBuilder(originalGroup)).build()); this.provider.getSalGroupService().updateGroup(builder.build()); }