Example usage for org.eclipse.jgit.internal.ketch Proposal isDone

List of usage examples for org.eclipse.jgit.internal.ketch Proposal isDone

Introduction

In this page you can find the example usage for org.eclipse.jgit.internal.ketch Proposal isDone.

Prototype

public boolean isDone() 

Source Link

Document

Whether the proposal was attempted

Usage

From source file:org.uberfire.java.nio.fs.jgit.util.commands.RefTreeUpdateCommand.java

License:Apache License

private void proposeKetch(final List<Command> n, final RevCommit _commit)
        throws IOException, InterruptedException {
    final Proposal proposal = new Proposal(n).setAuthor(_commit.getAuthorIdent()).setMessage("push");
    git.getKetchLeader().queueProposal(proposal);
    if (proposal.isDone()) {
        // This failed fast, e.g. conflict or bad precondition.
        throw new GitException("Error");
    }// w w w  .  jav a 2 s .c om
    if (proposal.getState() == QUEUED) {
        waitForQueue(proposal);
    }
    if (!proposal.isDone()) {
        waitForPropose(proposal);
    }
}