コード例 #1
0
 public void TestXmlWriter()
 {
     Repository repo = new Repository();
     PingSender pingSender = new PingSender();
     ARPSender arpSender = new ARPSender();
     Task task1 = Task.Factory.StartNew( () =>
     {
         for( int i = 0 ; i < 10 ; i++ )
         {
             Task task2 = Task.Factory.StartNew( () =>
             {
                 repo.AddOrUpdate( IPAddress.Parse( "10.8.99.121" ), pingSender.Ping( IPAddress.Parse( "10.8.99.121" ) ) );
                 repo.AddOrUpdate( IPAddress.Parse( "10.8.99.121" ), arpSender.GetMac( IPAddress.Parse( "10.8.99.121" ) ) );
             } );
         }
         Thread.Sleep( 5000 );
     } ).ContinueWith( ( a ) =>
     {
         //pour le moment voir direct dans le dossier
         //repo.XmlWriter();
     } );
 }
コード例 #2
0
ファイル: GridWindow.cs プロジェクト: LudovicT/Grid-Mapper
 private void diagramDisplayControl1_Load(object sender, EventArgs e)
 {
     Repository repo = new Repository();
 }