public RemoveDefine ( MagickFormat format, string name ) : void | ||
format | MagickFormat | The format to set the define for. |
name | string | The name of the define. |
return | void |
private void ExecuteRemoveDefine(XmlElement element, MagickSettings settings) { Hashtable arguments = new Hashtable(); foreach (XmlAttribute attribute in element.Attributes) { if (attribute.Name == "format") { arguments["format"] = Variables.GetValue <MagickFormat>(attribute); } else if (attribute.Name == "name") { arguments["name"] = Variables.GetValue <String>(attribute); } } if (OnlyContains(arguments, "format", "name")) { settings.RemoveDefine((MagickFormat)arguments["format"], (String)arguments["name"]); } else if (OnlyContains(arguments, "name")) { settings.RemoveDefine((String)arguments["name"]); } else { throw new ArgumentException("Invalid argument combination for 'removeDefine', allowed combinations are: [format, name] [name]"); } }
private void ExecuteRemoveDefine(XmlElement element, MagickSettings settings) { Hashtable arguments = new Hashtable(); foreach (XmlAttribute attribute in element.Attributes) { if (attribute.Name == "format") arguments["format"] = Variables.GetValue<MagickFormat>(attribute); else if (attribute.Name == "name") arguments["name"] = Variables.GetValue<String>(attribute); } if (OnlyContains(arguments, "format", "name")) settings.RemoveDefine((MagickFormat)arguments["format"], (String)arguments["name"]); else if (OnlyContains(arguments, "name")) settings.RemoveDefine((String)arguments["name"]); else throw new ArgumentException("Invalid argument combination for 'removeDefine', allowed combinations are: [format, name] [name]"); }