return false; if (!Objects.equals(_nsp, other.getNsp())) { return false;
private NshAddDelMap getNshAddDelMapRequest(final boolean isAdd, final int mapIndex, @Nonnull final NshMap map, @Nonnull final MappingContext ctx) { final NshAddDelMap request = new NshAddDelMap(); request.isAdd = booleanToByte(isAdd); request.nspNsi = (map.getNsp().intValue()<<8) | map.getNsi(); request.mappedNspNsi = (map.getMappedNsp().intValue()<<8) | map.getMappedNsi(); if (map.getEncapType() == VxlanGpe.class) { request.nextNode = 2; } checkState(interfaceContext.containsIndex(map.getEncapIfName(), ctx), "Mapping does not contains mapping for provider interface Name ".concat(map.getEncapIfName())); request.swIfIndex = interfaceContext.getIndex(map.getEncapIfName(), ctx); return request; } }
public NshMapBuilder(NshMap base) { if (base.getKey() == null) { this._key = new NshMapKey( base.getName() ); this._name = base.getName(); } else { this._key = base.getKey(); this._name = _key.getName(); } this._encapIfName = base.getEncapIfName(); this._encapType = base.getEncapType(); this._mappedNsi = base.getMappedNsi(); this._mappedNsp = base.getMappedNsp(); this._nsi = base.getNsi(); this._nsp = base.getNsp(); if (base instanceof NshMapImpl) { NshMapImpl impl = (NshMapImpl) 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.params.xml.ns.yang.vpp.nsh.rev160624.vpp.nsh.nsh.maps.NshMap> casted =(AugmentationHolder<org.opendaylight.yang.gen.v1.urn.opendaylight.params.xml.ns.yang.vpp.nsh.rev160624.vpp.nsh.nsh.maps.NshMap>) base; if (!casted.augmentations().isEmpty()) { this.augmentation = new HashMap<>(casted.augmentations()); } } }