예제 #1
0
 public static Type Resolve(IList entity)
 {
     if (entity == null || entity.Count == 0)
     {
         throw new ArgumentException("Missing or Empty entity graphs list.");
     }
     //
     return(ObjectResolver.GetTransactionType(entity.GetType().Name));
 }
예제 #2
0
 public static Type Resolve(ActionContext actionContext)
 {
     if (actionContext == null)
     {
         throw new ArgumentException("Unspecified (null) context object.");
     }
     //
     if (actionContext.Graph == null || actionContext.Graph.Count == 0)
     {
         throw new ArgumentException("Missing or Empty entity graphs list.");
     }
     //
     return(ObjectResolver.GetTransactionType(actionContext.Graph[0].Split('.')[0]));
 }
예제 #3
0
 public static Type Resolve(string objectName, bool isTransactionObject = true)
 {
     return(ObjectResolver.GetTransactionType(objectName, isTransactionObject));
 }