02.08.2012, 10:50
Funciona sim. O IP й 32 bits. Sгo 4 cйlulas de 1 byte de dados cada (atй 255). 8 x 4 = 32.
Ele pode ser representado como uma int e dado parse para float.
O motivo de ter dado NaN, provavelmente, deve ter se dado а mantissa nгo ter nenhum dado e o expoente estar no canto direito (deve estar no esquerdo), dando valores invбlidos, pelo padrгo IEEE (http://en.wikipedia.org/wiki/IEEE_floating_point)
Ele pode ser representado como uma int e dado parse para float.
Quote:
Address representations IPv4 addresses may be written in any notation expressing a 32-bit integer value, but for human convenience, they are most often written in the dot-decimal notation, which consists of four octets of the address expressed individually in decimal and separated by periods. The following table shows several representation formats: |