private FabricAclImpl(FabricAclBuilder base) { if (base.getKey() == null) { this._key = new FabricAclKey( base.getFabricAclName() ); this._fabricAclName = base.getFabricAclName(); } else { this._key = base.getKey(); this._fabricAclName = _key.getFabricAclName(); } 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.faas.fabric.type.rev150930.acl.list.FabricAcl>>, Augmentation<org.opendaylight.yang.gen.v1.urn.opendaylight.faas.fabric.type.rev150930.acl.list.FabricAcl>> e = base.augmentation.entrySet().iterator().next(); this.augmentation = Collections.<java.lang.Class<? extends Augmentation<org.opendaylight.yang.gen.v1.urn.opendaylight.faas.fabric.type.rev150930.acl.list.FabricAcl>>, Augmentation<org.opendaylight.yang.gen.v1.urn.opendaylight.faas.fabric.type.rev150930.acl.list.FabricAcl>>singletonMap(e.getKey(), e.getValue()); break; default : this.augmentation = new HashMap<>(base.augmentation); } }
public FabricAclBuilder(FabricAcl base) { if (base.getKey() == null) { this._key = new FabricAclKey( base.getFabricAclName() ); this._fabricAclName = base.getFabricAclName(); } else { this._key = base.getKey(); this._fabricAclName = _key.getFabricAclName(); } if (base instanceof FabricAclImpl) { FabricAclImpl impl = (FabricAclImpl) base; if (!impl.augmentation.isEmpty()) { this.augmentation = new HashMap<>(impl.augmentation); } } else if (base instanceof AugmentationHolder) { @SuppressWarnings("unchecked") AugmentationHolder<org.opendaylight.yang.gen.v1.urn.opendaylight.faas.fabric.type.rev150930.acl.list.FabricAcl> casted =(AugmentationHolder<org.opendaylight.yang.gen.v1.urn.opendaylight.faas.fabric.type.rev150930.acl.list.FabricAcl>) base; if (!casted.augmentations().isEmpty()) { this.augmentation = new HashMap<>(casted.augmentations()); } } }
@Override public void aclUpdated(InstanceIdentifier<FabricAcl> iid, boolean isDelete) { InstanceIdentifier<TerminationPoint> tpiid = iid.firstIdentifierOf(TerminationPoint.class); String aclName = iid.firstKeyOf(FabricAcl.class).getFabricAclName(); if (tpiid != null) { if (isDelete) {