Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 10 of 12 for createTempFile (0.23 sec)

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

        File temp1 = createTempFile();
        File temp2 = createTempFile();
    
        Files.copy(i18nFile, temp1);
        moveHelper(true, temp1, temp2);
        assertTrue(Files.equal(temp2, i18nFile));
      }
    
      public void testMoveViaCopy() throws IOException {
        File i18nFile = getTestFile("i18n.txt");
        File temp1 = createTempFile();
        File temp2 = createTempFile();
    
        Files.copy(i18nFile, temp1);
    Java
    - Registered: Fri Apr 19 12:43:09 GMT 2024
    - Last Modified: Wed Sep 06 17:04:31 GMT 2023
    - 22.2K bytes
    - Viewed (0)
  2. android/guava-tests/test/com/google/common/io/FilesTest.java

        File temp1 = createTempFile();
        File temp2 = createTempFile();
    
        Files.copy(i18nFile, temp1);
        moveHelper(true, temp1, temp2);
        assertTrue(Files.equal(temp2, i18nFile));
      }
    
      public void testMoveViaCopy() throws IOException {
        File i18nFile = getTestFile("i18n.txt");
        File temp1 = createTempFile();
        File temp2 = createTempFile();
    
        Files.copy(i18nFile, temp1);
    Java
    - Registered: Fri May 03 12:43:13 GMT 2024
    - Last Modified: Wed Sep 06 17:04:31 GMT 2023
    - 22.2K bytes
    - Viewed (0)
  3. android/guava/src/com/google/common/io/TempFileCreator.java

          } catch (IOException e) {
            throw new IllegalStateException("Failed to create directory", e);
          }
        }
    
        @Override
        File createTempFile(String prefix) throws IOException {
          return java.nio.file.Files.createTempFile(
                  Paths.get(JAVA_IO_TMPDIR.value()),
                  /* prefix= */ prefix,
                  /* suffix= */ null,
                  filePermissions.get())
    Java
    - Registered: Fri Apr 26 12:43:10 GMT 2024
    - Last Modified: Fri Oct 06 17:11:11 GMT 2023
    - 12.5K bytes
    - Viewed (0)
  4. guava-tests/test/com/google/common/io/MoreFilesTest.java

                  }
                  Files.deleteIfExists(dir);
                  return FileVisitResult.CONTINUE;
                }
              });
        }
      }
    
      private Path createTempFile() throws IOException {
        return Files.createTempFile(tempDir, "test", ".test");
      }
    
      public void testByteSource_size_ofDirectory() throws IOException {
        try (FileSystem fs = Jimfs.newFileSystem(Configuration.unix())) {
    Java
    - Registered: Fri Apr 19 12:43:09 GMT 2024
    - Last Modified: Mon Jan 29 22:57:05 GMT 2024
    - 27.2K bytes
    - Viewed (0)
  5. android/guava-tests/test/com/google/common/io/ResourcesTest.java

        // Check that we can find a resource if it is visible to the context class
        // loader, even if it is not visible to the loader of the Resources class.
    
        File tempFile = createTempFile();
        PrintWriter writer = new PrintWriter(tempFile, "UTF-8");
        writer.println("rud a chur ar an méar fhada");
        writer.close();
    
        // First check that we can't find it without setting the context loader.
    Java
    - Registered: Fri May 03 12:43:13 GMT 2024
    - Last Modified: Wed Sep 06 17:04:31 GMT 2023
    - 6.8K bytes
    - Viewed (0)
  6. android/guava/src/com/google/common/io/FileBackedOutputStream.java

       * so.
       */
      @GuardedBy("this")
      private void update(int len) throws IOException {
        if (memory != null && (memory.getCount() + len > fileThreshold)) {
          File temp = TempFileCreator.INSTANCE.createTempFile("FileBackedOutputStream");
          if (resetOnFinalize) {
            // Finalizers are not guaranteed to be called on system shutdown;
            // this is insurance.
            temp.deleteOnExit();
          }
          try {
    Java
    - Registered: Fri Apr 26 12:43:10 GMT 2024
    - Last Modified: Thu Feb 22 17:40:56 GMT 2024
    - 8.2K bytes
    - Viewed (0)
  7. 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)
  8. guava-tests/test/com/google/common/io/ResourcesTest.java

        // Check that we can find a resource if it is visible to the context class
        // loader, even if it is not visible to the loader of the Resources class.
    
        File tempFile = createTempFile();
        PrintWriter writer = new PrintWriter(tempFile, "UTF-8");
        writer.println("rud a chur ar an méar fhada");
        writer.close();
    
        // First check that we can't find it without setting the context loader.
    Java
    - Registered: Fri Apr 12 12:43:09 GMT 2024
    - Last Modified: Wed Sep 06 17:04:31 GMT 2023
    - 6.8K bytes
    - Viewed (0)
  9. android/guava-tests/test/com/google/common/reflect/ClassPathTest.java

      }
    
      @AndroidIncompatible // ClassPath is documented as not supporting Android
    
      public void testScan_classPathCycle() throws IOException {
        File jarFile = File.createTempFile("with_circular_class_path", ".jar");
        try {
          writeSelfReferencingJarFile(jarFile, "test.txt");
          assertThat(
                  new ClassPath.LocationInfo(jarFile, ClassPathTest.class.getClassLoader())
    Java
    - Registered: Fri May 03 12:43:13 GMT 2024
    - Last Modified: Fri Apr 26 14:02:27 GMT 2024
    - 24.9K bytes
    - Viewed (0)
  10. guava-tests/test/com/google/common/reflect/ClassPathTest.java

      }
    
      @AndroidIncompatible // ClassPath is documented as not supporting Android
    
      public void testScan_classPathCycle() throws IOException {
        File jarFile = File.createTempFile("with_circular_class_path", ".jar");
        try {
          writeSelfReferencingJarFile(jarFile, "test.txt");
          assertThat(
                  new ClassPath.LocationInfo(jarFile, ClassPathTest.class.getClassLoader())
    Java
    - Registered: Fri Apr 12 12:43:09 GMT 2024
    - Last Modified: Mon Jul 10 17:06:37 GMT 2023
    - 27.7K bytes
    - Viewed (0)
Back to top