Examples of BadlyFormattedFlowExecutionKeyException


Examples of org.springframework.webflow.execution.repository.BadlyFormattedFlowExecutionKeyException

    final String[] keyParts = CasFlowExecutionKey.keyParts(encodedKey);
    final UUID uuid;
    try {
        uuid = UUID.fromString(keyParts[0]);
    } catch (Exception e) {
      throw new BadlyFormattedFlowExecutionKeyException(encodedKey, CasFlowExecutionKey.FORMAT);
    }
    Serializable executionId = parseExecutionId(keyParts[1], encodedKey);
    Serializable snapshotId = parseSnapshotId(keyParts[2], encodedKey);
    validateUUID(uuid, executionId);
    return new CasFlowExecutionKey(executionId, snapshotId, uuid);
View Full Code Here

Examples of org.springframework.webflow.execution.repository.BadlyFormattedFlowExecutionKeyException

  private ConversationId parseExecutionId(final String encodedId, final String encodedKey) throws BadlyFormattedFlowExecutionKeyException {
    try {
      return this.conversationManager.parseConversationId(encodedId);
    } catch (ConversationException e) {
      throw new BadlyFormattedFlowExecutionKeyException(encodedKey, CompositeFlowExecutionKey.getFormat(), e);
    }
  }
View Full Code Here

Examples of org.springframework.webflow.execution.repository.BadlyFormattedFlowExecutionKeyException

  private Serializable parseSnapshotId(final String encodedId, final String encodedKey) throws BadlyFormattedFlowExecutionKeyException {
    try {
      return Integer.valueOf(encodedId);
    } catch (NumberFormatException e) {
      throw new BadlyFormattedFlowExecutionKeyException(encodedKey, CompositeFlowExecutionKey.getFormat(), e);
    }
  }
View Full Code Here

Examples of org.springframework.webflow.execution.repository.BadlyFormattedFlowExecutionKeyException

  // implementing flow execution repository

  public FlowExecutionKey parseFlowExecutionKey(String encodedKey) throws FlowExecutionRepositoryException {
    if (!StringUtils.hasText(encodedKey)) {
      throw new BadlyFormattedFlowExecutionKeyException(encodedKey,
          "The string-encoded flow execution key is required");
    }
    String[] keyParts = CompositeFlowExecutionKey.keyParts(encodedKey);
    Serializable executionId = parseExecutionId(keyParts[0], encodedKey);
    Serializable snapshotId = parseSnapshotId(keyParts[1], encodedKey);
View Full Code Here

Examples of org.springframework.webflow.execution.repository.BadlyFormattedFlowExecutionKeyException

  private ConversationId parseExecutionId(String encodedId, String encodedKey)
      throws BadlyFormattedFlowExecutionKeyException {
    try {
      return conversationManager.parseConversationId(encodedId);
    } catch (ConversationException e) {
      throw new BadlyFormattedFlowExecutionKeyException(encodedKey, CompositeFlowExecutionKey.getFormat(), e);
    }
  }
View Full Code Here

Examples of org.springframework.webflow.execution.repository.BadlyFormattedFlowExecutionKeyException

  private Serializable parseSnapshotId(String encodedId, String encodedKey)
      throws BadlyFormattedFlowExecutionKeyException {
    try {
      return Integer.valueOf(encodedId);
    } catch (NumberFormatException e) {
      throw new BadlyFormattedFlowExecutionKeyException(encodedKey, CompositeFlowExecutionKey.getFormat(), e);
    }
  }
View Full Code Here

Examples of org.springframework.webflow.execution.repository.BadlyFormattedFlowExecutionKeyException

   * @param encodedKey the string-encoded composite flow execution key
   * @return the composite key parts as a String array (executionId = 0, snapshotId = 1)
   */
  public static String[] keyParts(String encodedKey) throws BadlyFormattedFlowExecutionKeyException {
    if (!encodedKey.startsWith(EXECUTION_ID_PREFIX)) {
      throw new BadlyFormattedFlowExecutionKeyException(encodedKey, FORMAT);
    }
    int snapshotStart = encodedKey.indexOf(SNAPSHOT_ID_PREFIX, EXECUTION_ID_PREFIX.length());
    if (snapshotStart == -1) {
      throw new BadlyFormattedFlowExecutionKeyException(encodedKey, FORMAT);
    }
    String executionId = encodedKey.substring(EXECUTION_ID_PREFIX.length(), snapshotStart);
    String snapshotId = encodedKey.substring(snapshotStart + SNAPSHOT_ID_PREFIX.length());
    return new String[] { executionId, snapshotId };
  }
View Full Code Here

Examples of org.springframework.webflow.execution.repository.BadlyFormattedFlowExecutionKeyException

  // implementing flow execution repository

  public FlowExecutionKey parseFlowExecutionKey(String encodedKey) throws FlowExecutionRepositoryException {
    if (!StringUtils.hasText(encodedKey)) {
      throw new BadlyFormattedFlowExecutionKeyException(encodedKey,
          "The string-encoded flow execution key is required");
    }
    String[] keyParts = CompositeFlowExecutionKey.keyParts(encodedKey);
    Serializable executionId = parseExecutionId(keyParts[0], encodedKey);
    Serializable snapshotId = parseSnapshotId(keyParts[1], encodedKey);
View Full Code Here

Examples of org.springframework.webflow.execution.repository.BadlyFormattedFlowExecutionKeyException

  private ConversationId parseExecutionId(String encodedId, String encodedKey)
      throws BadlyFormattedFlowExecutionKeyException {
    try {
      return conversationManager.parseConversationId(encodedId);
    } catch (ConversationException e) {
      throw new BadlyFormattedFlowExecutionKeyException(encodedKey, CompositeFlowExecutionKey.getFormat(), e);
    }
  }
View Full Code Here

Examples of org.springframework.webflow.execution.repository.BadlyFormattedFlowExecutionKeyException

  private Serializable parseSnapshotId(String encodedId, String encodedKey)
      throws BadlyFormattedFlowExecutionKeyException {
    try {
      return Integer.valueOf(encodedId);
    } catch (NumberFormatException e) {
      throw new BadlyFormattedFlowExecutionKeyException(encodedKey, CompositeFlowExecutionKey.getFormat(), e);
    }
  }
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.