Print() public méthode

public Print ( string str ) : void
str string
Résultat void
Exemple #1
0
 public void SaveContents()
 {
     if (volume.SaveFile(loadingPath, new FileContent(contents)) == null)
     {
         // For some reason the normal trap that prints exceptions on
         // the terminal doesn't work here in this part of the code,
         // thus the two messages:
         term.Print("[File Save failed. Check space on device?]");
         throw new Exception("File Save Failed from Text Editor.");
     }
     isDirty = false;
     term.Print("[Saved changes to " + loadingPath + "]");
 }
Exemple #2
0
        public void SaveContents()
        {
            var file = new ProgramFile(fileName);

            file.StringContent = contents;

            if (!volume.SaveFile(file))
            {
                // For some reason the normal trap that prints exceptions on
                // the terminal doesn't work here in this part of the code,
                // thus the two messages:
                term.Print("[File Save failed. Check space on device?]");
                throw new Exception("File Save Failed from Text Editor.");
            }
            isDirty = false;
            term.Print("[Saved changes to " + fileName + "]");
        }