示例#1
0
 private void CreateCaches(MefCacheCommand command)
 {
     if (command.All || command.NotSpecific)
     {
         caches.AddRange(new List <Cache> {
             new Vs2012Cache(), new Vs2013Cache(), new Vs2015Cache(), new Vs2017Cache()
         });
     }
     else
     {
         if (command.Vs2012)
         {
             caches.Add(new Vs2012Cache());
         }
         if (command.Vs2013)
         {
             caches.Add(new Vs2013Cache());
         }
         if (command.Vs2015)
         {
             caches.Add(new Vs2015Cache());
         }
         if (command.Vs2017)
         {
             caches.Add(new Vs2017Cache());
         }
     }
 }
示例#2
0
 public int Execute(MefCacheCommand command)
 {
     MefCacheCommand = command;
     CreateCaches(command);
     VerifyExistenceOfCache();
     if (command.Fix)
     {
         DeleteCaches();
     }
     return(0);
 }