Package cleo.search.connection

Examples of cleo.search.connection.RandomConnectionFilter


 
  public void testRandomConnectionFilter() {
    int source = rand.nextInt(100000);
    int target = rand.nextInt(100000);
    Connection conn = new SimpleConnection(source, target, true);
    ConnectionFilter connFilter = new RandomConnectionFilter();
   
    boolean rejected = false;
    boolean accepted = false;
   
    while(!rejected) {
      rejected = !connFilter.accept(conn);
    }
   
    while(!accepted) {
      accepted = connFilter.accept(conn);
    }
   
    assertEquals(true, rejected);
    assertEquals(true, accepted);
  }
View Full Code Here

TOP

Related Classes of cleo.search.connection.RandomConnectionFilter

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.