private NeighborImpl(NeighborBuilder base) { if (base.getKey() == null) { this._key = new NeighborKey( base.getIp() ); this._ip = base.getIp(); } else { this._key = base.getKey(); this._ip = _key.getIp(); } this._linkLayerAddress = base.getLinkLayerAddress(); this._origin = base.getOrigin(); 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.ietf.params.xml.ns.yang.ietf.ip.rev140616.interfaces.state._interface.ipv4.Neighbor>>, Augmentation<org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.ip.rev140616.interfaces.state._interface.ipv4.Neighbor>> e = base.augmentation.entrySet().iterator().next(); this.augmentation = Collections.<java.lang.Class<? extends Augmentation<org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.ip.rev140616.interfaces.state._interface.ipv4.Neighbor>>, Augmentation<org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.ip.rev140616.interfaces.state._interface.ipv4.Neighbor>>singletonMap(e.getKey(), e.getValue()); break; default : this.augmentation = new HashMap<>(base.augmentation); } }
private NeighborImpl(NeighborBuilder base) { if (base.getKey() == null) { this._key = new NeighborKey( base.getIp() ); this._ip = base.getIp(); } else { this._key = base.getKey(); this._ip = _key.getIp(); } this._linkLayerAddress = base.getLinkLayerAddress(); this._origin = base.getOrigin(); 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.ietf.params.xml.ns.yang.ietf.ip.rev140616.interfaces.state._interface.ipv4.Neighbor>>, Augmentation<org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.ip.rev140616.interfaces.state._interface.ipv4.Neighbor>> e = base.augmentation.entrySet().iterator().next(); this.augmentation = Collections.<java.lang.Class<? extends Augmentation<org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.ip.rev140616.interfaces.state._interface.ipv4.Neighbor>>, Augmentation<org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.ip.rev140616.interfaces.state._interface.ipv4.Neighbor>>singletonMap(e.getKey(), e.getValue()); break; default : this.augmentation = new HashMap<>(base.augmentation); } }
public NeighborBuilder(Neighbor base) { if (base.getKey() == null) { this._key = new NeighborKey( base.getIp() ); this._ip = base.getIp(); } else { this._key = base.getKey(); this._ip = _key.getIp(); } this._linkLayerAddress = base.getLinkLayerAddress(); this._origin = base.getOrigin(); if (base instanceof NeighborImpl) { NeighborImpl impl = (NeighborImpl) 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.ietf.params.xml.ns.yang.ietf.ip.rev140616.interfaces.state._interface.ipv4.Neighbor> casted =(AugmentationHolder<org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.ip.rev140616.interfaces.state._interface.ipv4.Neighbor>) base; if (!casted.augmentations().isEmpty()) { this.augmentation = new HashMap<>(casted.augmentations()); } } }
public NeighborBuilder(Neighbor base) { if (base.key() == null) { this.key = new NeighborKey( base.getIp() ); this._ip = base.getIp(); } else { this.key = base.key(); this._ip = key.getIp(); } this._linkLayerAddress = base.getLinkLayerAddress(); this._origin = base.getOrigin(); if (base instanceof NeighborImpl) { NeighborImpl impl = (NeighborImpl) base; if (!impl.augmentation.isEmpty()) { this.augmentation = new HashMap<>(impl.augmentation); } } else if (base instanceof AugmentationHolder) { @SuppressWarnings("unchecked") AugmentationHolder<Neighbor> casted =(AugmentationHolder<Neighbor>) base; if (!casted.augmentations().isEmpty()) { this.augmentation = new HashMap<>(casted.augmentations()); } } }
public NeighborBuilder(Neighbor base) { if (base.getKey() == null) { this._key = new NeighborKey( base.getIp() ); this._ip = base.getIp(); } else { this._key = base.getKey(); this._ip = _key.getIp(); } this._linkLayerAddress = base.getLinkLayerAddress(); this._origin = base.getOrigin(); if (base instanceof NeighborImpl) { NeighborImpl impl = (NeighborImpl) 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.ietf.params.xml.ns.yang.ietf.ip.rev140616.interfaces.state._interface.ipv4.Neighbor> casted =(AugmentationHolder<org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.ip.rev140616.interfaces.state._interface.ipv4.Neighbor>) base; if (!casted.augmentations().isEmpty()) { this.augmentation = new HashMap<>(casted.augmentations()); } } }
NeighborImpl(NeighborBuilder base) { if (base.key() != null) { this.key = base.key(); } else { this.key = new NeighborKey(base.getIp()); } this._ip = key.getIp(); this._linkLayerAddress = base.getLinkLayerAddress(); this._origin = base.getOrigin(); this.augmentation = ImmutableMap.copyOf(base.augmentation); }
private NeighborImpl(NeighborBuilder base) { if (base.key() == null) { this.key = new NeighborKey( base.getIp() ); this._ip = base.getIp(); } else { this.key = base.key(); this._ip = key.getIp(); } this._linkLayerAddress = base.getLinkLayerAddress(); this._origin = base.getOrigin(); this.augmentation = ImmutableMap.copyOf(base.augmentation); }