コード例 #1
0
 public void SendCommand(string command)
 {
     if (command == ".")
     {
         command = LastCommand;
     }
     else
     {
         LastCommand = command;
     }
     this.serverConnection.SendText(command);
     SentCommands.Enqueue(command);
     if (SentCommands.Count > 30)
     {
         SentCommands.Dequeue();
     }
 }
コード例 #2
0
ファイル: TransferStub.cs プロジェクト: Valks/tftp.net
 public bool CommandWasSent(Type commandType)
 {
     return(SentCommands.Any(x => x.GetType().IsAssignableFrom(commandType)));
 }