Search Options

Results per page
Sort
Preferred Languages
Advance

Results 51 - 60 of 64 for createTempFile (0.22 sec)

  1. android/guava-tests/test/com/google/common/io/ByteStreamsTest.java

        ByteArrayOutputStream out = new ByteArrayOutputStream();
        WritableByteChannel outChannel = Channels.newChannel(out);
    
        File testFile = createTempFile();
        byte[] dummyData = newPreFilledByteArray(chunkSize);
        try (FileOutputStream fos = new FileOutputStream(testFile)) {
          for (int i = 0; i < 500; i++) {
            fos.write(dummyData);
          }
        }
    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)
  2. android/guava/src/com/google/common/io/Files.java

       * href="https://github.com/google/guava/issues/4011">CVE-2020-8908</a>.)
       *
       * <p>Use this method instead of {@link File#createTempFile(String, String)} when you wish to
       * create a directory, not a regular file. A common pitfall is to call {@code createTempFile},
       * delete the file and create a directory in its place, but this leads a race condition which can
    Java
    - Registered: Fri Apr 26 12:43:10 GMT 2024
    - Last Modified: Thu Feb 15 16:12:13 GMT 2024
    - 33.1K bytes
    - Viewed (0)
  3. okhttp/src/test/java/okhttp3/RequestTest.kt

        assertThat(bodyToHex(body)).isEqualTo("48656c6c6f")
        assertThat(bodyToHex(body), "Retransmit body").isEqualTo("48656c6c6f")
      }
    
      @Test
      fun file() {
        val file = File.createTempFile("RequestTest", "tmp")
        val writer = FileWriter(file)
        writer.write("abc")
        writer.close()
        val contentType = "text/plain".toMediaType()
        val body: RequestBody = file.asRequestBody(contentType)
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Mon Jan 08 01:13:22 GMT 2024
    - 16.4K bytes
    - Viewed (0)
  4. src/main/java/org/codelibs/fess/exec/Crawler.java

                systemProperties.reload(options.propertiesPath);
            } else {
                try {
                    final File propFile = ComponentUtil.getSystemHelper().createTempFile("crawler_", ".properties");
                    if (propFile.delete() && logger.isDebugEnabled()) {
                        logger.debug("Deleted a temp file: {}", propFile.getAbsolutePath());
                    }
    Java
    - Registered: Mon May 06 08:04:11 GMT 2024
    - Last Modified: Thu Feb 22 01:37:57 GMT 2024
    - 24.1K bytes
    - Viewed (2)
  5. guava-tests/test/com/google/common/io/ByteStreamsTest.java

        ByteArrayOutputStream out = new ByteArrayOutputStream();
        WritableByteChannel outChannel = Channels.newChannel(out);
    
        File testFile = createTempFile();
        byte[] dummyData = newPreFilledByteArray(chunkSize);
        try (FileOutputStream fos = new FileOutputStream(testFile)) {
          for (int i = 0; i < 500; i++) {
            fos.write(dummyData);
          }
        }
    Java
    - Registered: Fri Apr 19 12:43:09 GMT 2024
    - Last Modified: Wed Sep 06 17:04:31 GMT 2023
    - 21.9K bytes
    - Viewed (0)
  6. src/test/java/org/codelibs/fess/helper/CrawlingConfigHelperTest.java

        private CrawlingConfigHelper crawlingConfigHelper;
    
        @Override
        public void setUp() throws Exception {
            super.setUp();
            final File propFile = File.createTempFile("system", ".properties");
            propFile.deleteOnExit();
            FileUtil.writeBytes(propFile.getAbsolutePath(), "".getBytes());
            ComponentUtil.register(new DynamicProperties(propFile), "systemProperties");
    Java
    - Registered: Mon May 06 08:04:11 GMT 2024
    - Last Modified: Thu Feb 22 01:37:57 GMT 2024
    - 23.2K bytes
    - Viewed (0)
  7. maven-compat/src/main/java/org/apache/maven/repository/legacy/DefaultWagonManager.java

                for (String extension : checksums.keySet()) {
                    // TODO shouldn't need a file intermediary - improve wagon to take a stream
                    File temp = File.createTempFile("maven-artifact", null);
                    temp.deleteOnExit();
                    byte[] bytes = sums.get(extension).getBytes(StandardCharsets.UTF_8);
                    Files.write(
    Java
    - Registered: Sun May 05 03:35:11 GMT 2024
    - Last Modified: Thu Sep 14 11:48:15 GMT 2023
    - 29.9K bytes
    - Viewed (0)
  8. src/main/java/org/codelibs/fess/app/web/admin/backup/AdminBackupAction.java

            validate(form, messages -> {}, this::asListHtml);
            verifyToken(this::asListHtml);
            final String fileName = form.bulkFile.getFileName();
            final File tempFile = ComponentUtil.getSystemHelper().createTempFile("fess_restore_", ".tmp");
            try (final InputStream in = form.bulkFile.getInputStream(); final OutputStream out = new FileOutputStream(tempFile)) {
                CopyUtil.copy(in, out);
    Java
    - Registered: Mon May 06 08:04:11 GMT 2024
    - Last Modified: Thu Feb 22 01:37:57 GMT 2024
    - 25.2K bytes
    - Viewed (0)
  9. okhttp/src/test/java/okhttp3/EventListenerTest.kt

      private fun enableCache(): Cache? {
        cache = makeCache()
        client = client.newBuilder().cache(cache).build()
        return cache
      }
    
      private fun makeCache(): Cache {
        val cacheDir = File.createTempFile("cache-", ".dir")
        cacheDir.delete()
        return Cache(cacheDir, (1024 * 1024).toLong())
      }
    
      companion object {
        val anyResponse = CoreMatchers.any(Response::class.java)
      }
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Sat Jan 20 10:30:28 GMT 2024
    - 56.9K bytes
    - Viewed (0)
  10. maven-core/src/test/resources/apiv4-repo/org/codehaus/plexus/plexus-utils/1.1/plexus-utils-1.1.jar

    String, String) throws java.io.IOException; public static void copyDirectoryStructu(java.io.File, java.io.File) throws java.io.IOException; public static void rename(java.io.File, java.io.File) throws java.io.IOException; public static java.io.File createTempFile(String, String, java.io.File); static void <clinit>(); } org/codehaus/plexus/util/interpolation/EnvarBasedValueSourc.class package org.codehaus.plexus.util.interpolation; public synchronized class EnvarBasedValueSourc implements ValueSource {...
    Archive
    - Registered: Sun Apr 21 03:35:09 GMT 2024
    - Last Modified: Sun Oct 02 08:41:25 GMT 2022
    - 164.6K bytes
    - Viewed (0)
Back to top