Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 10 of 155 for getBytes (0.23 sec)

  1. guava-tests/test/com/google/common/hash/MacHashFunctionTest.java

          new SecretKeySpec("secret key".getBytes(UTF_8), "HmacMD5");
      private static final SecretKey SHA1_KEY =
          new SecretKeySpec("secret key".getBytes(UTF_8), "HmacSHA1");
      private static final SecretKey SHA256_KEY =
          new SecretKeySpec("secret key".getBytes(UTF_8), "HmacSHA256");
      private static final SecretKey SHA512_KEY =
          new SecretKeySpec("secret key".getBytes(UTF_8), "HmacSHA512");
    
    Java
    - Registered: Fri Apr 19 12:43:09 GMT 2024
    - Last Modified: Wed Sep 06 17:04:31 GMT 2023
    - 13.8K bytes
    - Viewed (0)
  2. guava-tests/test/com/google/common/base/CharsetsTest.java

      @GwtIncompatible // Non-UTF-8 Charset
      public void testWhyUsAsciiIsDangerous() {
        byte[] b1 = "朝日新聞".getBytes(Charsets.US_ASCII);
        byte[] b2 = "聞朝日新".getBytes(Charsets.US_ASCII);
        byte[] b3 = "????".getBytes(Charsets.US_ASCII);
        byte[] b4 = "ニュース".getBytes(Charsets.US_ASCII);
        byte[] b5 = "スューー".getBytes(Charsets.US_ASCII);
        // Assert they are all equal (using the transitive property)
        assertTrue(Arrays.equals(b1, b2));
    Java
    - Registered: Fri Apr 19 12:43:09 GMT 2024
    - Last Modified: Thu May 04 09:41:29 GMT 2023
    - 2.5K bytes
    - Viewed (0)
  3. android/guava-tests/test/com/google/common/io/ByteSinkTest.java

        assertTrue(sink.wasStreamClosed());
        assertArrayEquals(new byte[] {1, 2, 3, 4}, sink.getBytes());
      }
    
      public void testWrite_bytes() throws IOException {
        assertArrayEquals(new byte[0], sink.getBytes());
        sink.write(bytes);
    
        assertTrue(sink.wasStreamOpened() && sink.wasStreamClosed());
        assertArrayEquals(bytes, sink.getBytes());
      }
    
      public void testWriteFrom_inputStream() throws IOException {
    Java
    - Registered: Fri May 03 12:43:13 GMT 2024
    - Last Modified: Wed Sep 06 17:04:31 GMT 2023
    - 3.7K bytes
    - Viewed (0)
  4. src/main/java/org/codelibs/fess/app/service/SearchLogService.java

                return buckets.stream().map(e -> {
                    final Map<String, Object> map = new HashMap<>();
                    map.put(ID, Base64.getUrlEncoder().encodeToString(e.getKeyAsString().getBytes(StandardCharsets.UTF_8)));
                    map.put(KEY, e.getKeyAsString());
                    map.put(COUNT, e.getDocCount());
                    return map;
                }).collect(Collectors.toList());
    Java
    - Registered: Mon Apr 29 08:04:11 GMT 2024
    - Last Modified: Thu Feb 22 01:37:57 GMT 2024
    - 28.4K bytes
    - Viewed (0)
  5. android/guava-tests/test/com/google/common/hash/MacHashFunctionTest.java

          new SecretKeySpec("secret key".getBytes(UTF_8), "HmacMD5");
      private static final SecretKey SHA1_KEY =
          new SecretKeySpec("secret key".getBytes(UTF_8), "HmacSHA1");
      private static final SecretKey SHA256_KEY =
          new SecretKeySpec("secret key".getBytes(UTF_8), "HmacSHA256");
      private static final SecretKey SHA512_KEY =
          new SecretKeySpec("secret key".getBytes(UTF_8), "HmacSHA512");
    
    Java
    - Registered: Fri May 03 12:43:13 GMT 2024
    - Last Modified: Wed Sep 06 17:04:31 GMT 2023
    - 13.8K bytes
    - Viewed (0)
  6. src/main/java/org/codelibs/fess/app/web/api/admin/stats/ApiAdminStatsAction.java

            jvmMemoryObj.heap = jvmMemoryHeapObj;
            jvmMemoryHeapObj.used = mem.getHeapUsed().getBytes();
            jvmMemoryHeapObj.committed = mem.getHeapCommitted().getBytes();
            jvmMemoryHeapObj.max = mem.getHeapMax().getBytes();
            jvmMemoryHeapObj.percent = mem.getHeapUsedPercent();
            final JvmMemoryNonHeapObj jvmMemoryNonHeapObj = new JvmMemoryNonHeapObj();
    Java
    - Registered: Mon Apr 29 08:04:11 GMT 2024
    - Last Modified: Thu Feb 22 01:37:57 GMT 2024
    - 12.1K bytes
    - Viewed (0)
  7. src/main/java/jcifs/util/Strings.java

         */
        public static byte[] getBytes ( String str, Charset encoding ) {
            if ( str == null ) {
                return new byte[0];
            }
            return str.getBytes(encoding);
        }
    
    
        /**
         * 
         * @param str
         * @return the string as bytes (UTF16-LE)
         */
        public static byte[] getUNIBytes ( String str ) {
            return getBytes(str, UNI_ENCODING);
        }
    
    
        /**
    Java
    - Registered: Sun May 05 00:10:10 GMT 2024
    - Last Modified: Mon Mar 13 12:00:57 GMT 2023
    - 4.9K bytes
    - Viewed (0)
  8. android/guava-tests/test/com/google/common/base/CharsetsTest.java

      @GwtIncompatible // Non-UTF-8 Charset
      public void testWhyUsAsciiIsDangerous() {
        byte[] b1 = "朝日新聞".getBytes(Charsets.US_ASCII);
        byte[] b2 = "聞朝日新".getBytes(Charsets.US_ASCII);
        byte[] b3 = "????".getBytes(Charsets.US_ASCII);
        byte[] b4 = "ニュース".getBytes(Charsets.US_ASCII);
        byte[] b5 = "スューー".getBytes(Charsets.US_ASCII);
        // Assert they are all equal (using the transitive property)
        assertTrue(Arrays.equals(b1, b2));
    Java
    - Registered: Fri May 03 12:43:13 GMT 2024
    - Last Modified: Thu May 04 09:41:29 GMT 2023
    - 2.5K bytes
    - Viewed (0)
  9. src/main/java/org/codelibs/fess/timer/SystemMonitorTarget.java

            buf.append("\"memory\":{");
            buf.append("\"heap\":{");
            append(buf, "used", () -> mem.getHeapUsed().getBytes()).append(',');
            append(buf, "committed", () -> mem.getHeapCommitted().getBytes()).append(',');
            append(buf, "max", () -> mem.getHeapMax().getBytes()).append(',');
            append(buf, "percent", () -> mem.getHeapUsedPercent());
            buf.append("},");
            buf.append("\"non_heap\":{");
    Java
    - Registered: Mon Apr 29 08:04:11 GMT 2024
    - Last Modified: Thu Feb 22 01:37:57 GMT 2024
    - 7.5K bytes
    - Viewed (0)
  10. android/guava-tests/test/com/google/common/io/ByteStreamsTest.java

        byte[] data = new byte[17];
        data[1] = 15;
        System.arraycopy("Kilroy was here".getBytes(Charsets.UTF_8), 0, data, 2, 15);
        ByteArrayDataInput in = ByteStreams.newDataInput(data);
        assertEquals("Kilroy was here", in.readUTF());
      }
    
      public void testNewDataInput_readChar() {
        byte[] data = "qed".getBytes(Charsets.UTF_16BE);
        ByteArrayDataInput in = ByteStreams.newDataInput(data);
    Java
    - Registered: Fri May 03 12:43:13 GMT 2024
    - Last Modified: Wed Sep 06 17:04:31 GMT 2023
    - 21.9K bytes
    - Viewed (0)
Back to top