Examples of State


Examples of com.google.appengine.tools.pipeline.impl.model.JobRecord.State

    runBarrier.setReleased();
    UpdateSpec tempSpec = new UpdateSpec(rootJobKey);
    tempSpec.getOrCreateTransaction("releaseRunBarrier").includeBarrier(runBarrier);
    backEnd.save(tempSpec, jobRecord.getQueueSettings());

    State jobState = jobRecord.getState();
    switch (jobState) {
      case WAITING_TO_RUN:
      case RETRY:
        // OK, proceed
        break;
View Full Code Here

Examples of com.google.collide.codemirror2.State

    @Override
    public CompletionContext<State> buildContext(
        SelectionModel selection, DocumentParser parser) {
      JsonArray<Token> tokens = JsonCollections.createArray();
      State state = TestUtils.createMockState();
      tokens.add(new Token(null, NULL, ""));
      ParseResult<State> parseResult = new ParseResult<State>(tokens, state) {};
      return buildContext(
          new ParseUtils.ExtendedParseResult<State>(parseResult, ParseUtils.Context.IN_CODE));
    }
View Full Code Here

Examples of com.google.common.util.concurrent.Service.State

   * @throws IllegalStateException if any of the Services are not {@link State#NEW new} when the
   *     method is called.
   */
  public ServiceManager startAsync() {
    for (Service service : services) {
      State state = service.state();
      checkState(state == NEW, "Service %s is %s, cannot start it.", service, state);
    }
    for (Service service : services) {
      try {
        service.startAsync();
View Full Code Here

Examples of com.google.gdata.data.projecthosting.State

        }

        // Set the completion date, this allows Mylyn mark the issue as
        // completed
        // There is no API for this so we make an educated guess
        State state = issueEntry.getState();
        if (!data.isNew() && Value.CLOSED == state.getValue()) {
            // find the last comment that set the issue status to the current
            // value
            // it would be better to find the last comment to set that state to
            // closed
            // but as long as we can't do that this will have to do
View Full Code Here

Examples of com.google.gwt.touch.client.Momentum.State

   * Test updating the state before the acceleration falls below the minimum
   * acceleration.
   */
  public void testUpdateStateFast() {
    DefaultMomentum momentum = new DefaultMomentum();
    State state = momentum.createState(new Point(0.0, 0.0), new Point(1.0, 2.0));
    state.setPosition(new Point(0.1, 0.2));
    state.setCumulativeElapsedMillis(10);
    state.setElapsedMillis(5);

    assertTrue(momentum.updateState(state));

    // Check the new velocity.
    Point velocity = state.getVelocity();
    assertEquals(0.99302, velocity.getX(), 0.000009); // 1.0 * .9993 ^ 10
    assertEquals(1.98604, velocity.getY(), 0.000009); // 2.0 * .9993 ^ 10

    // Check the new position.
    Point position = state.getPosition();
    assertEquals(5.0651, position.getX(), 0.0001); // .1 + v * 5ms
    assertEquals(10.1302, position.getY(), 0.0001); // .2 + v * 5ms5
  }
View Full Code Here

Examples of com.google.web.bindery.requestfactory.shared.impl.AbstractRequestContext.State

    }
    return returnValue;
  }

  public static AbstractRequestContext requestContext(AutoBean<?> bean) {
    State state = bean.<AbstractRequestContext.State> getTag(REQUEST_CONTEXT_STATE);
    return state == null ? null : state.getCanonicalContext();
  }
View Full Code Here

Examples of com.google_voltpatches.common.util.concurrent.Service.State

   * @throws IllegalStateException if any of the Services are not {@link State#NEW new} when the
   *     method is called.
   */
  public ServiceManager startAsync() {
    for (Service service : services) {
      State state = service.state();
      checkState(state == NEW, "Service %s is %s, cannot start it.", service, state);
    }
    for (Service service : services) {
      try {
        state.tryStartTiming(service);
        service.startAsync();
      } catch (IllegalStateException e) {
        // This can happen if the service has already been started or stopped (e.g. by another
        // service or listener). Our contract says it is safe to call this method if
        // all services were NEW when it was called, and this has already been verified above, so we
View Full Code Here

Examples of com.hazelcast.transaction.impl.Transaction.State

        if (tx == null) {
            final XAException xaException = new XAException(XAException.XAER_NOTA);
            logger.severe("Transaction is not available!!!", xaException);
            throw xaException;
        }
        final State txState = tx.getState();
        switch (state) {
            case ACTIVE:
                if (txState != State.ACTIVE) {
                    final XAException xaException = new XAException(XAException.XAER_NOTA);
                    logger.severe("Transaction is not active!!! state: " + txState, xaException);
View Full Code Here

Examples of com.jada.jpa.entity.State

      StateDisplayForm stateForm = states[i];
      if (stateForm.getRemove() == null) {
        continue;
      }
      if (stateForm.getRemove().equals(String.valueOf(Constants.VALUE_YES))) {
        State state = StateDAO.load(site.getSiteId(), Format.getLong(stateForm.getStateId()));
        country.getStates().remove(state);
        em.remove(state);
      }
    }
   
View Full Code Here

Examples of com.jpetrak.gate.stringannotation.extendedgazetteer2.State

   *
   * @param toMatch
   * @return
   */
  public Iterator<Lookup> match(String toMatch) {
    State currentState = getInitialState();
    for (int i = 0; i < toMatch.length(); i++) {
      char currentChar = toMatch.charAt(i);
      currentState = currentState.next(currentChar);
      if (currentState == null) {
        break;
      }
      if (i==(toMatch.length()-1) && currentState.isFinal()) {  // we are at the last character
        return getLookups(currentState);
      }
    }
    return null;
  }
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.