Esempio n. 1
0
 public string ToFixedLengthText()
 {
     if (Title == null)
     {
         Title = "nulltitle";
     }
     if (Director == null)
     {
         Director = "nulldirector";
     }
     if (ReleaseDate == null)
     {
         ReleaseDate = "nulldate";
     }
     if (Genre == null)
     {
         Genre = "nullgenre";
     }
     return($"{Title.PadLeft(50, 'Ꮄ')}{Director.PadLeft(50, 'Ꮄ')}{ImdbRating:0.0}{ReleaseDate.PadLeft(11, 'Ꮄ')}{Genre.PadLeft(20, 'Ꮄ')}{RottenTomatoesRating:000}");
 }