Property definitions

socket $ SocketAddress :: defaultinit
# Address of a socket in the Internet namespace
#
# Used in one of the out parameters of `UDPSocket::recv_from`.
class SocketAddress
	super FinalizableOnce

	# FIXME make init private

	private var native: NativeSocketAddrIn

	init
	do
		address = native.address.to_s
		port = native.port
	end

	# Internet address
	var address: String is noinit

	# Port of the socket
	var port: Int is noinit

	redef fun ==(o) do return o isa SocketAddress and o.address == address and o.port == port

	redef fun finalize_once do native.free
end
lib/socket/socket.nit:467,1--492,3