The way to calculate new address

@param addr - creating addres
@param nonce - nonce of creating address
@return new address
167198
public static byte[] calcNewAddr(byte[] addr, byte[] nonce) {

        byte[] encSender = RLP.encodeElement(addr);
        byte[] encNonce = RLP.encodeBigInteger(new BigInteger(1, nonce));

        return sha3omit12(RLP.encodeList(encSender, encNonce));
    }
1092370
function HostEntry(addr, src) {
  if (!(this instanceof HostEntry))
    return new HostEntry(addr, src);

  this.addr = addr || new NetAddress();
  this.src = src || new NetAddress();
  this.prev = null;
  this.next = null;
  this.used = false;
  this.refCount = 0;
  this.attempts = 0;
  this.lastSuccess = 0;
  this.lastAttempt = 0;

  if (addr)
    this.fromOptions(addr, src);
}
1298041
def addr=(addr)
      @addr = addr
      @me = Node.new @id, @addr, true
      Directory[@id].address = addr
      ObjectSpace.define_finalizer(me, proc { Directory.remove @id })
    end
537191
public static InetAddress getByAddress(String host, byte[] addr, int scopeId)
        throws UnknownHostException {
        if (host != null && host.length() > 0 && host.charAt(0) == '[') {
            if (host.charAt(host.length()-1) == ']') {
                host = host.substring(1, host.length() -1);
            }
        }
        if (addr != null) {
            if (addr.length == Inet4Address.INADDRSZ) {
                return new Inet4Address(host, addr);
            } else if (addr.length == Inet6Address.INADDRSZ) {
                byte[] newAddr
                    = IPAddressUtil.convertFromIPv4MappedAddress(addr);
                if (newAddr != null) {
                    return new Inet4Address(host, newAddr);
                } else {
                    return new Inet6Address(host, addr, scopeId);
                }
            }
        }
        throw new UnknownHostException("addr is of illegal length");
    }
596667
public static int ipv4ToInt( final Inet4Address    addr )
    {
        int    value = 0;

        for( byte    chunk : addr.getAddress() )
        {
            value <<= 8;
            value |= chunk & 0xff;
        }

        return value;
    }
622111
public String getHostByAddr(byte [] addr) throws UnknownHostException {
	Name name = ReverseMap.fromAddress(InetAddress.getByAddress(addr));
	Record [] records = new Lookup(name, Type.PTR).run();
	if (records == null)
		throw new UnknownHostException();
	return ((PTRRecord) records[0]).getTarget().toString();
}
323684
def is_same_address(addr1, addr2):
    
    hostport1 = addr1.split(":")
    hostport2 = addr2.split(":")

    return (is_same_host(hostport1[0], hostport2[0]) and
            hostport1[1] == hostport2[1])
156085
def addr=(val)
      unless val.to_s =~ /^#{Util::RX_MAC_ADDR}$/
        raise(ArgumentError, "invalid mac address #{val.inspect}")
      end
      raw = Util.unhexify(val, /[:-]/)
      self[:data].to_ptr.write_string(raw, ETH_ADDR_LEN)
    end
131149
public static void inc(byte[] nonce, byte value) {
        int i = nonce.length - 1;
        nonce[i] += value;
        if (value > 0 && (nonce[i] < 0 || nonce[i] >= value))
            return;
        if (value < 0 && (nonce[i] < 0 && nonce[i] >= value))
            return;

        for (i = i - 1; i >= 0; i--) {
            nonce[i]++;
            if (nonce[i] != 0) break;
        }
    }
435698
def add(name, address)
      device = Device.new(name: name, address: address)
      self << device
      device
    end
581954
def new_address(self, prefix, type, callback=None, errback=None, **kwargs):
        
        if not self.data:
            raise NetworkException('Network not loaded')

        return Address(self.config, prefix, type, self).create(**kwargs)
568547
public static boolean isLocalAddress(final InetAddress addr)
	{
		if (addr.isLoopbackAddress())
		{
			return true;
		}

		try
		{
			Enumeration<NetworkInterface> nics = NetworkInterface.getNetworkInterfaces();

			while (nics.hasMoreElements())
			{
				Enumeration<InetAddress> addrs = nics.nextElement().getInetAddresses();

				while (addrs.hasMoreElements())
				{
					if (addrs.nextElement().equals(addr))
					{
						return true; // Search successful
					}
				}
			}
		}
		catch (SocketException e)
		{
			log.debug(e.getMessage(), e);
		}

		log.debug("[FileHelper] {isLocalAddress} not local: " + addr.getHostAddress());

		// Search failed
		return false;
	}
73710
def create_address(self, account_id, **params):
        """"""
        response = self._post('v2', 'accounts', account_id, 'addresses', data=params)
        return self._make_api_object(response, Address)
1175994
def parity_discover_next_available_nonce(
        web3: Web3,
        address: AddressHex,
) -> Nonce:
    """"""
    next_nonce_encoded = web3.manager.request_blocking('parity_nextNonce', [address])
    return Nonce(int(next_nonce_encoded, 16))
458050
public void writeAddress(IndividualAddress newAddress) throws KNXTimeoutException,
		KNXLinkClosedException
	{
		tl.broadcast(false, Priority.SYSTEM, DataUnitBuilder.createAPDU(IND_ADDR_WRITE,
			newAddress.toByteArray()));
	}
1118647
def _addr(self):
        
        group_by = self._config['address_group_by']

        assert not self._flags['address'], "{} address already assigned".format(self._name)
        assert group_by in ('element', 'variable')

        m0 = self.system.dae.m
        n0 = self.system.dae.n
        mend = m0 + len(self._algebs) * self.n
        nend = n0 + len(self._states) * self.n

        if group_by == 'variable':
            for idx, item in enumerate(self._algebs):
                self.__dict__[item] = list(
                    range(m0 + idx * self.n, m0 + (idx + 1) * self.n))
            for idx, item in enumerate(self._states):
                self.__dict__[item] = list(
                    range(n0 + idx * self.n, n0 + (idx + 1) * self.n))
        elif group_by == 'element':
            for idx, item in enumerate(self._algebs):
                self.__dict__[item] = list(
                    range(m0 + idx, mend, len(self._algebs)))
            for idx, item in enumerate(self._states):
                self.__dict__[item] = list(
                    range(n0 + idx, nend, len(self._states)))

        self.system.dae.m = mend
        self.system.dae.n = nend

        self._flags['address'] = True
239168
private static EndpointReferenceType createEPR(String address, SLProperties props) {
        EndpointReferenceType epr = WSAEndpointReferenceUtils.getEndpointReference(address);
        if (props != null) {
            addProperties(epr, props);
        }
        return epr;
    }