Examples of Clock


Examples of org.hibernate.search.test.query.Clock

public class PurgeTest extends SearchTestCase {

  public void testPurge() throws Exception {
    FullTextSession s = Search.getFullTextSession( openSession() );
    Transaction tx = s.beginTransaction();
    org.hibernate.search.test.query.Clock clock = new Clock( 1, "Seiko" );
    s.save( clock );
    clock = new Clock( 2, "Festina" );
    s.save( clock );
    Book book = new Book( 1, "La chute de la petite reine a travers les yeux de Festina", "La chute de la petite reine a travers les yeux de Festina, blahblah" );
    s.save( book );
    book = new Book( 2, "La gloire de mon p�re", "Les deboires de mon p�re en v�lo" );
    s.save( book );
View Full Code Here

Examples of org.javatari.general.board.Clock

      dataLine.open(AUDIO_FORMAT, OUTPUT_BUFFER_SIZE);
      inputBuffer = ByteBuffer.allocateDirect(INPUT_BUFFER_SIZE);
      tempBuffer = new byte[inputBuffer.capacity()];
      if (ADDED_THREAD_PRIORITY != 0) clock.setPriority(Thread.NORM_PRIORITY + ADDED_THREAD_PRIORITY);
      System.out.println("Sound Mixer Line: " + dataLine.getClass().getSimpleName());
      clock = new Clock("Speaker", this, FPS);
    } catch (Exception ex) {
      System.out.println("Unable to acquire audio line:\n" + ex);
      dataLine = null;
    }
  }
View Full Code Here

Examples of org.jboss.aerogear.security.otp.api.Clock

     *
     * @param secret Shared secret
     */
    public Totp(String secret) {
        this.secret = secret;
        clock = new Clock();
    }
View Full Code Here

Examples of org.opengis.temporal.Clock

    /**
     * Test of getClock method, of class DefaultCalendar.
     */
    @Test
    public void testGetClock() {
        Clock result = calendar1.getClock();
        assertEquals(calendar2.getClock(), result);
    }
View Full Code Here

Examples of org.openqa.selenium.support.ui.Clock

    }

    @Test
    public void page_should_pause_during_wait() throws InterruptedException {

        Clock clock = new org.openqa.selenium.support.ui.SystemClock();
        NormalFluentWait<WebDriver> waitFor = new NormalFluentWait(driver, clock, sleeper);
        Counter counter = new Counter();

        waitFor.withTimeoutOf(5000).milliseconds()
                .pollingEvery(100).milliseconds()
View Full Code Here

Examples of org.prevayler.Clock

      throws Exception {
    PrevaylerFactory<StringBuffer> factory = new PrevaylerFactory<StringBuffer>();
    factory.configurePrevalentSystem(new StringBuffer("the system"));
    factory.configurePrevalenceDirectory(_testDirectory);
    factory.configureJournalSerializer(suffix, journalSerializer);
    factory.configureClock(new Clock() {
      private long time = 1000000;

      public Date time() {
        return new Date(++time);
      }
View Full Code Here

Examples of org.prevayler.Clock

      throws Exception {
    PrevaylerFactory<StringBuffer> factory = new PrevaylerFactory<StringBuffer>();
    factory.configurePrevalentSystem(new StringBuffer("the system"));
    factory.configurePrevalenceDirectory(_testDirectory);
    factory.configureJournalSerializer(suffix, journalSerializer);
    factory.configureClock(new Clock() {
      private long time = 1000000;

      public Date time() {
        return new Date(++time);
      }
View Full Code Here

Examples of org.threeten.bp.Clock

    // now(Clock)
    //-----------------------------------------------------------------------
    @Test
    public void now_Clock() {
        Instant instant = LocalDateTime.of(2010, 12, 31, 0, 0).toInstant(ZoneOffset.UTC);
        Clock clock = Clock.fixed(instant, ZoneOffset.UTC);
        MonthDay test = MonthDay.now(clock);
        assertEquals(test.getMonth(), Month.DECEMBER);
        assertEquals(test.getDayOfMonth(), 31);
    }
View Full Code Here

Examples of ptolemy.actor.lib.Clock

        Parameter stopTime = (Parameter) director.getAttribute("stopTime");
        stopTime.setToken(new DoubleToken(57.0));
        topLevelActor.setManager(manager);

        // Set up next level actors
        Clock vowelSrc = new Clock(topLevelActor, "vowelSrc");
        vowelSrc.values.setExpression("{1,1,1,1,1,1,1,1,1,1,1,1,1}");
        vowelSrc.period.setToken(new DoubleToken(100.0));
        vowelSrc.offsets
                .setExpression("{0.5,2.0,5.0,7.0,8.0,11.0,12.5,13.5,14.0,15.5,17.5,19.5,20.5}");
        vowelSrc.stopTime.setToken(new DoubleToken(30.0));

        Clock consonantsSrc = new Clock(topLevelActor, "consonantsSrc");
        consonantsSrc.values
                .setExpression("{1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1}");
        consonantsSrc.period.setToken(new DoubleToken(100.0));
        consonantsSrc.offsets
                .setExpression("{0.0, 1.0, 1.5, 4.0, 4.5, 6.0, 6.5, 7.5, 8.5, 9.0, 10.0, 10.5, 12.0, 13.0, 14.5, 16.0, 17.0, 18.0, 18.5, 19.0, 20.0}");
        consonantsSrc.stopTime.setToken(new DoubleToken(30.0));

        Clock punctuationSrc = new Clock(topLevelActor, "punctuationSrc");
        punctuationSrc.values.setExpression("{1, 1, 1, 1, 1, 1, 1, 1, 1}");
        punctuationSrc.period.setToken(new DoubleToken(100.0));
        punctuationSrc.offsets
                .setExpression("{2.5, 3.0, 3.5, 5.5, 9.5, 11.5, 15.0, 16.5, 21.0}");
        punctuationSrc.stopTime.setToken(new DoubleToken(30.0));

        PrintString printer = new PrintString(topLevelActor, "printer");
        Consonants consonants = new Consonants(topLevelActor, "consonants");
        Vowels vowels = new Vowels(topLevelActor, "vowels");
        Punctuation punctuation = new Punctuation(topLevelActor, "punctuation");

        // System.out.println("Actors have been instantiated.");
        // Set up ports, relation
        TypedIOPort vSrcOut = (TypedIOPort) vowelSrc.getPort("output");
        TypedIOPort cSrcOut = (TypedIOPort) consonantsSrc.getPort("output");
        TypedIOPort pSrcOut = (TypedIOPort) punctuationSrc.getPort("output");

        TypedIOPort cOutput = (TypedIOPort) consonants.getPort("output");
        TypedIOPort vOutput = (TypedIOPort) vowels.getPort("output");
        TypedIOPort pOutput = (TypedIOPort) punctuation.getPort("output");
View Full Code Here

Examples of ptolemy.actor.lib.Clock

        Merge merge = new Merge(toplevel, "merge");

        // Create 20 clocks.
        for (int i = 1; i < 20; i++) {
            Clock clock = new Clock(toplevel, "clock" + i);
            clock.period.setExpression("" + (i * 2));
            clock.values.setExpression("{" + i + ", " + i + "}");
            toplevel.connect(clock.output, merge.input);
        }

View Full Code Here
TOP
Copyright © 2018 www.massapi.com. 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.