[Minor] added ServiceResult.error(String)
This commit is contained in:
parent
fa72314fcf
commit
a82cb7ae39
|
@ -116,6 +116,10 @@ public class ServiceResult implements Serializable {
|
|||
return new ServiceResult(ServiceResultState.WARNING, warning, t);
|
||||
}
|
||||
|
||||
public static ServiceResult error(String error) {
|
||||
return new ServiceResult(ServiceResultState.FAILED, error, null);
|
||||
}
|
||||
|
||||
public static ServiceResult failed(String error, Throwable t) {
|
||||
return new ServiceResult(ServiceResultState.FAILED, error, t);
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue