/// <summary> /// Constructor that register WMI Context and takes prepared Expression /// </summary> /// <param name="context">WMI Context instance to be registered</param> /// <param name="expression">Initial Expression</param> public WmiClassSet(WmiContext context, Expression expression) { _context = context; Expression = expression; }
private static T InvokeStaticMethod <T, TClass>(WmiContext wmiContext, string methodName, IDictionary <string, object> methodParameters) => wmiContext.Connection == null ? default : wmiContext.Connection.InvokeStaticMethod <T, TClass>(methodName, methodParameters);
/// <summary> /// Constructor that register WMI Context /// </summary> /// <param name="context">WMI Context instance to be registered</param> public WmiClassSet(WmiContext context) { _context = context; Expression = Expression.Constant(this); }