c# - Dry principle and using keyword -


how implement dry principle in following code? can eleminate multiple "using" keywords 1

   public void createfile()     {         using (filestream f1 = new filestream(@"c:\\test",filemode.create))         {          }      }     public void fontclass()     {         using (font f1 = new font("arial", 10.0f))         {         }     } 


Comments

Popular posts from this blog

matlab - Deleting rows with specific rules -

php - MySQLi multi_query results for later use -