Example #1
0
        public void Visit(FileMethods f)
        {
            string wat = f.getMytTxt();

            wat = encrypt(wat);
            var someStream = FileMethods.create(f.myFullPath() + "_encrypted");

            byte[] info = new UTF8Encoding(true).GetBytes(wat);
            someStream.Write(info, 0, info.Length);
            FileMethods.delete(f.myFullPath());
        }
Example #2
0
        public void Visit(FileMethods f)
        {
            myNum = -myNum;
            string wat = f.getMytTxt();

            wat = encryption(wat);
            var someStream = FileMethods.create(f.myFullPath().Remove(f.myFullPath().Length - 10, 10));

            byte[] info = new UTF8Encoding(true).GetBytes(wat);
            someStream.Write(info, 0, info.Length);
            FileMethods.delete(f.myFullPath());
        }
Example #3
0
 public override void createFile()
 {
     FileMethods.create(path + "\\newFile.txt");
 }