endian11

java追加写文件(android)

  •     private FileOutputStream fileOutputStream;
        private static final String FILENAME = "Hello";
     File file = new File(Environment.getExternalStorageDirectory()
                                    .getAbsolutePath(),FILENAME);
                            RandomAccessFile randomAccessFile = new RandomAccessFile(file,"rw");
                            randomAccessFile.seek(file.length());
                            randomAccessFile.writeBytes("hello,Kitty!!\r\n");
                            randomAccessFile.close();
    

      

分类:

技术点:

相关文章:

  • 2022-12-23
  • 2022-12-23
  • 2022-02-18
  • 2022-12-23
  • 2021-05-27
  • 2021-05-15
  • 2021-06-23
猜你喜欢
  • 2022-12-23
  • 2022-12-23
  • 2022-02-03
  • 2022-02-09
  • 2022-12-23
相关资源
相似解决方案