Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 3 of 3 for fromLittleEndianByteArray (0.23 sec)

  1. android/guava-tests/test/com/google/common/net/InetAddressesTest.java

      }
    
      public void testFromLittleEndianByteArray() throws UnknownHostException {
        assertEquals(
            InetAddresses.fromLittleEndianByteArray(new byte[] {1, 2, 3, 4}),
            InetAddress.getByAddress(new byte[] {4, 3, 2, 1}));
    
        assertEquals(
            InetAddresses.fromLittleEndianByteArray(
                new byte[] {1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16}),
            InetAddress.getByAddress(
    Java
    - Registered: Fri May 03 12:43:13 GMT 2024
    - Last Modified: Wed Sep 06 17:04:31 GMT 2023
    - 31.9K bytes
    - Viewed (0)
  2. guava-tests/test/com/google/common/net/InetAddressesTest.java

      }
    
      public void testFromLittleEndianByteArray() throws UnknownHostException {
        assertEquals(
            InetAddresses.fromLittleEndianByteArray(new byte[] {1, 2, 3, 4}),
            InetAddress.getByAddress(new byte[] {4, 3, 2, 1}));
    
        assertEquals(
            InetAddresses.fromLittleEndianByteArray(
                new byte[] {1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16}),
            InetAddress.getByAddress(
    Java
    - Registered: Fri Apr 12 12:43:09 GMT 2024
    - Last Modified: Wed Sep 06 17:04:31 GMT 2023
    - 31.9K bytes
    - Viewed (0)
  3. android/guava/src/com/google/common/net/InetAddresses.java

       * @return an InetAddress object created from the raw IP address
       * @throws UnknownHostException if IP address is of illegal length
       */
      public static InetAddress fromLittleEndianByteArray(byte[] addr) throws UnknownHostException {
        byte[] reversed = new byte[addr.length];
        for (int i = 0; i < addr.length; i++) {
          reversed[i] = addr[addr.length - i - 1];
        }
    Java
    - Registered: Fri Apr 26 12:43:10 GMT 2024
    - Last Modified: Fri Dec 15 19:31:54 GMT 2023
    - 44K bytes
    - Viewed (1)
Back to top