// Path: web/src/main/java/de/otto/jlineup/web/State.java
// public enum State {
//     BEFORE_PENDING("'before' pending"),
//     BEFORE_RUNNING("'before' running"),
//     BEFORE_DONE("'before' done"),
//     AFTER_PENDING("'after' pending"),
//     AFTER_RUNNING("'after' running"),
//     FINISHED_WITHOUT_DIFFERENCES("finished without differences"),
//     FINISHED_WITH_DIFFERENCES("finished with differences"),
//     ERROR("error"),
//     DEAD("dead");
// 
//     private final String humanReadableName;
// 
//     State(String humanReadableName) {
//         this.humanReadableName = humanReadableName;
//     }
// 
//     public String getHumanReadableName() {
//         return humanReadableName;
//     }
// 
//     public boolean isDone() {
//         return this == FINISHED_WITH_DIFFERENCES || this == FINISHED_WITHOUT_DIFFERENCES || this == ERROR || this == DEAD;
//     }
// 
//     public boolean isNonPersistable() {
//         return this == BEFORE_PENDING || this == BEFORE_RUNNING || this == AFTER_PENDING || this == AFTER_RUNNING;
//     }
// }


import de.otto.jlineup.web.State;
package de.otto.jlineup.service;


public class InvalidRunStateException extends Exception {

    private final String id;
// Path: web/src/main/java/de/otto/jlineup/web/State.java
// public enum State {
//     BEFORE_PENDING("'before' pending"),
//     BEFORE_RUNNING("'before' running"),
//     BEFORE_DONE("'before' done"),
//     AFTER_PENDING("'after' pending"),
//     AFTER_RUNNING("'after' running"),
//     FINISHED_WITHOUT_DIFFERENCES("finished without differences"),
//     FINISHED_WITH_DIFFERENCES("finished with differences"),
//     ERROR("error"),
//     DEAD("dead");
// 
//     private final String humanReadableName;
// 
//     State(String humanReadableName) {
//         this.humanReadableName = humanReadableName;
//     }
// 
//     public String getHumanReadableName() {
//         return humanReadableName;
//     }
// 
//     public boolean isDone() {
//         return this == FINISHED_WITH_DIFFERENCES || this == FINISHED_WITHOUT_DIFFERENCES || this == ERROR || this == DEAD;
//     }
// 
//     public boolean isNonPersistable() {
//         return this == BEFORE_PENDING || this == BEFORE_RUNNING || this == AFTER_PENDING || this == AFTER_RUNNING;
//     }
// }


// Path: web/src/main/java/de/otto/jlineup/service/InvalidRunStateException.java
import de.otto.jlineup.web.State;

package de.otto.jlineup.service;


public class InvalidRunStateException extends Exception {

    private final String id;
    private final State currentState;