Package cnslab.cnsnetwork

Examples of cnslab.cnsnetwork.PRun


        lockObject = new Object ( );
     
      final CyclicBarrier
        cyclicBarrier = new CyclicBarrier ( 2 );
     
      final PRun
        pRun = new PRun (
          network.getDiscreteEventQueue ( ),
          network,
          lockObject,
          cyclicBarrier );
     
      final Runnable  runnable = new Runnable ( )
      {
        @Override
        public void run ( )
        {
          try
          {
            cyclicBarrier.await ( );
           
            Thread.sleep ( 5 * 60 * 1000 );           
          }
          catch ( Exception e )
          {
            e.printStackTrace();
          }
          finally
          {
            network.stop = true;
           
            network.trialDone = true;
          }
        }
      };
     
      new Thread ( runnable ).start ( );
     
      pRun.run ( );
    }
View Full Code Here


     
      network.init ( );
     
      final CyclicBarrier  cyclicBarrier = new CyclicBarrier ( 1 );
     
      final PRun  pRun = new PRun (
        network.getDiscreteEventQueue ( ),
        network,
        new Object ( ), // lock
        cyclicBarrier );
     
View Full Code Here

TOP

Related Classes of cnslab.cnsnetwork.PRun

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.