public abstract Remove ( string name, bool verbose = false ) : void | ||
name | string | |
verbose | bool | |
return | void |
public void Remove(PrintManagerBridge instance) { try { instance.Remove(Name); } catch (Exception ex) { Log.Error(LogName, "Could not remove"); Log.Error(LogName, ex); } }
public void Remove(PrintManagerBridge instance, bool verbose = false) { Log.Entry("Printer", "Removing: " + Name); try { instance.Remove(Name, verbose); } catch (Exception ex) { Log.Error(LogName, "Could not remove"); Log.Error(LogName, ex); } }
private void RemoveExtraPrinters(List <Printer> newPrinters, DataContracts.PrinterManager msg, List <string> installedPrinters) { var managedPrinters = newPrinters.Where(printer => printer != null).Select(printer => printer.Name).ToList(); if (!msg.Mode.Equals("ar", StringComparison.OrdinalIgnoreCase)) { foreach (var name in msg.AllPrinters.Where(name => !managedPrinters.Contains(name) && installedPrinters.Contains(name))) { CleanPrinter(name, true); } } else { foreach (var name in installedPrinters.Where(name => !managedPrinters.Contains(name))) { _instance.Remove(name); } } }
public void Remove(PrintManagerBridge instance, bool verbose = false) { Log.Entry("Printer", "Removing: " + Name); try { instance.Remove(Name, verbose); } catch (Exception ex) { Log.Error(LogName, "Could not remove"); Log.Error(LogName, ex); } }