
io.github.vipcxj.jasync.spec.BreakException Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of jasync-spec Show documentation
Show all versions of jasync-spec Show documentation
JAsync implements Async-Await fashion for Java just like es and c#.
This library provide the spec of all public api.
package io.github.vipcxj.jasync.spec;
public class BreakException extends JAsyncException {
private static final long serialVersionUID = -6532237818800947165L;
private String label;
public BreakException(String label) {
super("", null, false, false);
this.label = label;
}
public boolean matchLabel(String label) {
return matchLabel(label, false);
}
public boolean matchLabel(String label, boolean block) {
if (!block && this.label == null) {
return true;
} else if (block && this.label == null) {
return false;
} else {
return this.label.equals(label);
}
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy