mirror of
https://github.com/reactos/reactos.git
synced 2025-06-12 03:48:30 +00:00
Support multiple channels
svn path=/trunk/; revision=13604
This commit is contained in:
parent
6536947239
commit
70350430a5
15 changed files with 251 additions and 109 deletions
|
@ -6,7 +6,8 @@ namespace TechBot.Console
|
|||
{
|
||||
public class ConsoleServiceOutput : IServiceOutput
|
||||
{
|
||||
public void WriteLine(string message)
|
||||
public void WriteLine(MessageContext context,
|
||||
string message)
|
||||
{
|
||||
System.Console.WriteLine(message);
|
||||
}
|
||||
|
@ -49,11 +50,11 @@ namespace TechBot.Console
|
|||
}
|
||||
}
|
||||
|
||||
private static string IRCChannelName
|
||||
private static string IRCChannelNames
|
||||
{
|
||||
get
|
||||
{
|
||||
string optionName = "IRCChannelName";
|
||||
string optionName = "IRCChannelNames";
|
||||
string s = ConfigurationSettings.AppSettings[optionName];
|
||||
VerifyRequiredOption(optionName,
|
||||
s);
|
||||
|
@ -149,7 +150,7 @@ namespace TechBot.Console
|
|||
{
|
||||
IrcService ircService = new IrcService(IRCServerHostName,
|
||||
IRCServerHostPort,
|
||||
IRCChannelName,
|
||||
IRCChannelNames,
|
||||
IRCBotName,
|
||||
ChmPath,
|
||||
MainChm,
|
||||
|
@ -180,7 +181,8 @@ namespace TechBot.Console
|
|||
while (true)
|
||||
{
|
||||
string s = System.Console.ReadLine();
|
||||
service.InjectMessage(s);
|
||||
service.InjectMessage(null,
|
||||
s);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue