示例#1
0
        public static PersistenceResponse <T> Fail(List <string> errors)
        {
            var result = new PersistenceResponse <T> {
                Succeeded = false, Errors = errors
            };

            return(result);
        }
示例#2
0
        public static PersistenceResponse <T> Fail(string message)
        {
            var result = new PersistenceResponse <T> {
                Succeeded = false, Message = message
            };

            return(result);
        }
示例#3
0
        public static PersistenceResponse <T> Success(T data, string message)
        {
            var result = new PersistenceResponse <T> {
                Succeeded = true, Data = data, Message = message
            };

            return(result);
        }
示例#4
0
        public static PersistenceResponse <T> Fail()
        {
            var result = new PersistenceResponse <T> {
                Succeeded = false
            };

            return(result);
        }
示例#5
0
        public static PersistenceResponse <T> Success()
        {
            var result = new PersistenceResponse <T> {
                Succeeded = true
            };

            return(result);
        }