// <autoperform new_channel="/action" /> public override void OnChannelCreated( IrcView view, IrcView.Channel channel ) { foreach ( XmlNode node in Settings.XML.SelectNodes("//autoperform") ) { foreach ( XmlAttribute attribute in node.Attributes ) switch ( attribute.Name ) { case "new_channel": view.ExecuteOn( channel, attribute.Value ); break; default: throw new FormatException( "Unexpected attribute "+attribute.Name+" in <autoperform/> tag" ); } } }