SWF-752 - FacesMessage.SEVERITY_FATAL does not propagate through FlowFacesContext
This commit is contained in:
@@ -38,6 +38,7 @@ import org.springframework.core.style.ToStringCreator;
|
||||
* </code>
|
||||
* </p>
|
||||
* @author Keith Donald
|
||||
* @author Jeremy Grelle
|
||||
*/
|
||||
public class MessageBuilder {
|
||||
|
||||
@@ -78,6 +79,15 @@ public class MessageBuilder {
|
||||
return this;
|
||||
}
|
||||
|
||||
/**
|
||||
* Records that the message being built is a fatal message.
|
||||
* @return this, for fluent API usage
|
||||
*/
|
||||
public MessageBuilder fatal() {
|
||||
severity = Severity.FATAL;
|
||||
return this;
|
||||
}
|
||||
|
||||
/**
|
||||
* Records that the message being built is against the provided source.
|
||||
* @param source the source generating the message
|
||||
|
||||
@@ -21,6 +21,7 @@ import org.springframework.core.enums.StaticLabeledEnum;
|
||||
* Enum exposing supported message severities.
|
||||
*
|
||||
* @author Keith Donald
|
||||
* @author Jeremy Grelle
|
||||
* @see Message
|
||||
*/
|
||||
public class Severity extends StaticLabeledEnum {
|
||||
@@ -37,10 +38,15 @@ public class Severity extends StaticLabeledEnum {
|
||||
public static final Severity WARNING = new Severity(1, "Warning");
|
||||
|
||||
/**
|
||||
* THe "Error" severity. Used to indicate a significant problem like a business rule violation.
|
||||
* The "Error" severity. Used to indicate a significant problem like a business rule violation.
|
||||
*/
|
||||
public static final Severity ERROR = new Severity(2, "Error");
|
||||
|
||||
/**
|
||||
* The "Fatal" severity. Used to indicate a fatal problem like a system error.
|
||||
*/
|
||||
public static final Severity FATAL = new Severity(3, "Fatal");
|
||||
|
||||
private Severity(int code, String label) {
|
||||
super(code, label);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user