public static TRSR <T> FromSR(TCore.SR sr) { TRSR <T> vsr = new TRSR <T>(); vsr.Result = sr.Result; vsr.Reason = sr.Reason; return(vsr); }
public static RSR ToRsr(TRSR <T> sr) { RSR rsr = new RSR(); rsr.Reason = sr.Reason; rsr.Result = sr.Result; return(rsr); }
public static TRSR <T> Failed(Exception e) { TRSR <T> sr = new TRSR <T>(); sr.Result = false; sr.Reason = e.Message; return(sr); }
public static TRSR <T> Failed(string sReason) { TRSR <T> sr = new TRSR <T>(); sr.Result = false; sr.Reason = sReason; return(sr); }
public static TRSR <T> Success() { TRSR <T> sr = new TRSR <T>(); sr.Result = true; sr.Reason = null; return(sr); }