public System.UInt32 SetByPrinterObject(System.Boolean?inCollate, System.Boolean?inColor, System.UInt32?inDuplexingMode, System.UInt32?inPaperSize, MSFTPrinter inPrinterObject, System.String inPrintTicketXML) { var parameters = new CimMethodParametersCollection(); if (inCollate.HasValue) { parameters.Add(CimMethodParameter.Create("Collate", inCollate.Value, CimFlags.None)); } if (inColor.HasValue) { parameters.Add(CimMethodParameter.Create("Color", inColor.Value, CimFlags.None)); } if (inDuplexingMode.HasValue) { parameters.Add(CimMethodParameter.Create("DuplexingMode", inDuplexingMode.Value, CimFlags.None)); } if (inPaperSize.HasValue) { parameters.Add(CimMethodParameter.Create("PaperSize", inPaperSize.Value, CimFlags.None)); } if (inPrinterObject != null) { parameters.Add(CimMethodParameter.Create("PrinterObject", inPrinterObject.AsCimInstance(), CimType.Instance, inPrinterObject == null ? CimFlags.NullValue : CimFlags.None)); } if (inPrintTicketXML != null) { parameters.Add(CimMethodParameter.Create("PrintTicketXML", inPrintTicketXML, CimType.String, inPrintTicketXML == null ? CimFlags.NullValue : CimFlags.None)); } var result = InfrastuctureObjectScope.CimSession.InvokeMethod(InnerCimInstance, "SetByPrinterObject", parameters); return((System.UInt32)result.ReturnValue.Value); }
public System.UInt32 AddCertBinding(System.String inApplicationId, System.String inCertificateHash, System.String inCertificateStoreName, System.String inIpPort, System.Boolean?inNullEncryption) { var parameters = new CimMethodParametersCollection(); if (inApplicationId != null) { parameters.Add(CimMethodParameter.Create("ApplicationId", inApplicationId, CimType.String, inApplicationId == null ? CimFlags.NullValue : CimFlags.None)); } if (inCertificateHash != null) { parameters.Add(CimMethodParameter.Create("CertificateHash", inCertificateHash, CimType.String, inCertificateHash == null ? CimFlags.NullValue : CimFlags.None)); } if (inCertificateStoreName != null) { parameters.Add(CimMethodParameter.Create("CertificateStoreName", inCertificateStoreName, CimType.String, inCertificateStoreName == null ? CimFlags.NullValue : CimFlags.None)); } if (inIpPort != null) { parameters.Add(CimMethodParameter.Create("IpPort", inIpPort, CimType.String, inIpPort == null ? CimFlags.NullValue : CimFlags.None)); } if (inNullEncryption.HasValue) { parameters.Add(CimMethodParameter.Create("NullEncryption", inNullEncryption.Value, CimFlags.None)); } var result = InfrastuctureObjectScope.CimSession.InvokeMethod(InnerCimInstance, "AddCertBinding", parameters); return((System.UInt32)result.ReturnValue.Value); }
public System.UInt32 AddByTcpPort(System.String inComputerName, System.String inName, System.UInt32?inPortNumber, System.String inPrinterHostAddress, System.UInt32?inSNMP, System.String inSNMPCommunity) { var parameters = new CimMethodParametersCollection(); if (inComputerName != null) { parameters.Add(CimMethodParameter.Create("ComputerName", inComputerName, CimType.String, inComputerName == null ? CimFlags.NullValue : CimFlags.None)); } if (inName != null) { parameters.Add(CimMethodParameter.Create("Name", inName, CimType.String, inName == null ? CimFlags.NullValue : CimFlags.None)); } if (inPortNumber.HasValue) { parameters.Add(CimMethodParameter.Create("PortNumber", inPortNumber.Value, CimFlags.None)); } if (inPrinterHostAddress != null) { parameters.Add(CimMethodParameter.Create("PrinterHostAddress", inPrinterHostAddress, CimType.String, inPrinterHostAddress == null ? CimFlags.NullValue : CimFlags.None)); } if (inSNMP.HasValue) { parameters.Add(CimMethodParameter.Create("SNMP", inSNMP.Value, CimFlags.None)); } if (inSNMPCommunity != null) { parameters.Add(CimMethodParameter.Create("SNMPCommunity", inSNMPCommunity, CimType.String, inSNMPCommunity == null ? CimFlags.NullValue : CimFlags.None)); } var result = InfrastuctureObjectScope.CimSession.InvokeMethod(InnerCimInstance, "AddByTcpPort", parameters); return((System.UInt32)result.ReturnValue.Value); }
public (System.UInt32 retval, MSFTNetISATAPConfiguration outOutputObject) Reset(System.Boolean?inPassThru, System.Boolean?inResolutionInterval, System.Boolean?inResolutionState, System.Boolean?inRouter, System.Boolean?inState) { var parameters = new CimMethodParametersCollection(); if (inPassThru.HasValue) { parameters.Add(CimMethodParameter.Create("PassThru", inPassThru.Value, CimFlags.None)); } if (inResolutionInterval.HasValue) { parameters.Add(CimMethodParameter.Create("ResolutionInterval", inResolutionInterval.Value, CimFlags.None)); } if (inResolutionState.HasValue) { parameters.Add(CimMethodParameter.Create("ResolutionState", inResolutionState.Value, CimFlags.None)); } if (inRouter.HasValue) { parameters.Add(CimMethodParameter.Create("Router", inRouter.Value, CimFlags.None)); } if (inState.HasValue) { parameters.Add(CimMethodParameter.Create("State", inState.Value, CimFlags.None)); } var result = InfrastuctureObjectScope.CimSession.InvokeMethod(InnerCimInstance, "Reset", parameters); return((System.UInt32)result.ReturnValue.Value, (MSFTNetISATAPConfiguration)InfrastuctureObjectScope.Mapper.Create(InfrastuctureObjectScope, (CimInstance)result.OutParameters["OutputObject"].Value)); }
public static void AddMembershipRule(string hostName, string userName, string passWord, string domain, string cmSite, string collectionId) { CimSession session = Connect(hostName, userName, passWord, domain); // Get All Collection // Add Exception catching chain var collectionInstance = session.EnumerateInstances($"root\\sms\\site_{cmSite}", "SMS_Collection") .Where(i => i.CimInstanceProperties["CollectionId"].Value.ToString().Contains(collectionId)).ToList(); if (!collectionInstance.Any()) { return; } var ruleInstance = new CimInstance(session.GetClass($"root\\sms\\site_{cmSite}", "SMS_CollectionRuleDirect")); ruleInstance.CimInstanceProperties["RuleName"].Value = ""; ruleInstance.CimInstanceProperties["ResourceClassName"].Value = "SMS_R_System"; ruleInstance.CimInstanceProperties["ResourceID"].Value = 1; var parameters = new CimMethodParametersCollection { CimMethodParameter.Create("collectionRule", ruleInstance, CimType.Instance, 0) }; CimMethodResult result = session.InvokeMethod(collectionInstance.FirstOrDefault(), "AddMembershipRule", parameters); }
public (System.UInt32 retval, IEnumerable <MSFTNetRoute> outCmdletOutput) Create(System.UInt16?inAddressFamily, System.UInt32?inCompartmentId, System.String inDestinationPrefix, System.String inInterfaceAlias, System.UInt32?inInterfaceIndex, System.String inNextHop, System.Boolean?inPassThru, System.String inPolicyStore, System.DateTime?inPreferredLifetime, System.UInt16?inProtocol, System.Byte?inPublish, System.UInt16?inRouteMetric, System.DateTime?inValidLifetime) { var parameters = new CimMethodParametersCollection(); if (inAddressFamily.HasValue) { parameters.Add(CimMethodParameter.Create("AddressFamily", inAddressFamily.Value, CimFlags.None)); } if (inCompartmentId.HasValue) { parameters.Add(CimMethodParameter.Create("CompartmentId", inCompartmentId.Value, CimFlags.None)); } if (inDestinationPrefix != null) { parameters.Add(CimMethodParameter.Create("DestinationPrefix", inDestinationPrefix, CimType.String, inDestinationPrefix == null ? CimFlags.NullValue : CimFlags.None)); } if (inInterfaceAlias != null) { parameters.Add(CimMethodParameter.Create("InterfaceAlias", inInterfaceAlias, CimType.String, inInterfaceAlias == null ? CimFlags.NullValue : CimFlags.None)); } if (inInterfaceIndex.HasValue) { parameters.Add(CimMethodParameter.Create("InterfaceIndex", inInterfaceIndex.Value, CimFlags.None)); } if (inNextHop != null) { parameters.Add(CimMethodParameter.Create("NextHop", inNextHop, CimType.String, inNextHop == null ? CimFlags.NullValue : CimFlags.None)); } if (inPassThru.HasValue) { parameters.Add(CimMethodParameter.Create("PassThru", inPassThru.Value, CimFlags.None)); } if (inPolicyStore != null) { parameters.Add(CimMethodParameter.Create("PolicyStore", inPolicyStore, CimType.String, inPolicyStore == null ? CimFlags.NullValue : CimFlags.None)); } if (inPreferredLifetime.HasValue) { parameters.Add(CimMethodParameter.Create("PreferredLifetime", inPreferredLifetime.Value, CimFlags.None)); } if (inProtocol.HasValue) { parameters.Add(CimMethodParameter.Create("Protocol", inProtocol.Value, CimFlags.None)); } if (inPublish.HasValue) { parameters.Add(CimMethodParameter.Create("Publish", inPublish.Value, CimFlags.None)); } if (inRouteMetric.HasValue) { parameters.Add(CimMethodParameter.Create("RouteMetric", inRouteMetric.Value, CimFlags.None)); } if (inValidLifetime.HasValue) { parameters.Add(CimMethodParameter.Create("ValidLifetime", inValidLifetime.Value, CimFlags.None)); } var result = InfrastuctureObjectScope.CimSession.InvokeMethod(InnerCimInstance, "Create", parameters); return((System.UInt32)result.ReturnValue.Value, (IEnumerable <MSFTNetRoute>)InfrastuctureObjectScope.Mapper.CreateMany <MSFTNetRoute>(InfrastuctureObjectScope, (IEnumerable <CimInstance>)result.OutParameters["CmdletOutput"].Value)); }
public (System.UInt32 retval, CIMConcreteJob outJob) TestReplicationConnection(System.UInt16?inAuthenticationType, System.Boolean?inBypassProxyServer, System.String inCertificateThumbPrint, System.String inRecoveryConnectionPoint, System.UInt16?inRecoveryServerPortNumber) { var parameters = new CimMethodParametersCollection(); if (inAuthenticationType.HasValue) { parameters.Add(CimMethodParameter.Create("AuthenticationType", inAuthenticationType.Value, CimFlags.None)); } if (inBypassProxyServer.HasValue) { parameters.Add(CimMethodParameter.Create("BypassProxyServer", inBypassProxyServer.Value, CimFlags.None)); } if (inCertificateThumbPrint != null) { parameters.Add(CimMethodParameter.Create("CertificateThumbPrint", inCertificateThumbPrint, CimType.String, inCertificateThumbPrint == null ? CimFlags.NullValue : CimFlags.None)); } if (inRecoveryConnectionPoint != null) { parameters.Add(CimMethodParameter.Create("RecoveryConnectionPoint", inRecoveryConnectionPoint, CimType.String, inRecoveryConnectionPoint == null ? CimFlags.NullValue : CimFlags.None)); } if (inRecoveryServerPortNumber.HasValue) { parameters.Add(CimMethodParameter.Create("RecoveryServerPortNumber", inRecoveryServerPortNumber.Value, CimFlags.None)); } var result = InfrastuctureObjectScope.CimSession.InvokeMethod(InnerCimInstance, "TestReplicationConnection", parameters); return((System.UInt32)result.ReturnValue.Value, (CIMConcreteJob)InfrastuctureObjectScope.Mapper.Create(InfrastuctureObjectScope, (CimInstance)result.OutParameters["Job"].Value)); }
public (System.UInt32 retval, IEnumerable <MSFTNetConSecRule> outCmdletOutput) Find(System.String inLocalAddress, System.UInt16?inLocalPort, System.String inProtocol, System.String inRemoteAddress, System.UInt16?inRemotePort) { var parameters = new CimMethodParametersCollection(); if (inLocalAddress != null) { parameters.Add(CimMethodParameter.Create("LocalAddress", inLocalAddress, CimType.String, inLocalAddress == null ? CimFlags.NullValue : CimFlags.None)); } if (inLocalPort.HasValue) { parameters.Add(CimMethodParameter.Create("LocalPort", inLocalPort.Value, CimFlags.None)); } if (inProtocol != null) { parameters.Add(CimMethodParameter.Create("Protocol", inProtocol, CimType.String, inProtocol == null ? CimFlags.NullValue : CimFlags.None)); } if (inRemoteAddress != null) { parameters.Add(CimMethodParameter.Create("RemoteAddress", inRemoteAddress, CimType.String, inRemoteAddress == null ? CimFlags.NullValue : CimFlags.None)); } if (inRemotePort.HasValue) { parameters.Add(CimMethodParameter.Create("RemotePort", inRemotePort.Value, CimFlags.None)); } var result = InfrastuctureObjectScope.CimSession.InvokeMethod(InnerCimInstance, "Find", parameters); return((System.UInt32)result.ReturnValue.Value, (IEnumerable <MSFTNetConSecRule>)InfrastuctureObjectScope.Mapper.CreateMany <MSFTNetConSecRule>(InfrastuctureObjectScope, (IEnumerable <CimInstance>)result.OutParameters["CmdletOutput"].Value)); }
public System.UInt32 JoinDomainOrWorkgroup(System.String inAccountOU, System.UInt32?inFJoinOptions, System.String inName, System.String inPassword, System.String inUserName) { var parameters = new CimMethodParametersCollection(); if (inAccountOU != null) { parameters.Add(CimMethodParameter.Create("AccountOU", inAccountOU, CimType.String, inAccountOU == null ? CimFlags.NullValue : CimFlags.None)); } if (inFJoinOptions.HasValue) { parameters.Add(CimMethodParameter.Create("FJoinOptions", inFJoinOptions.Value, CimFlags.None)); } if (inName != null) { parameters.Add(CimMethodParameter.Create("Name", inName, CimType.String, inName == null ? CimFlags.NullValue : CimFlags.None)); } if (inPassword != null) { parameters.Add(CimMethodParameter.Create("Password", inPassword, CimType.String, inPassword == null ? CimFlags.NullValue : CimFlags.None)); } if (inUserName != null) { parameters.Add(CimMethodParameter.Create("UserName", inUserName, CimType.String, inUserName == null ? CimFlags.NullValue : CimFlags.None)); } var result = InfrastuctureObjectScope.CimSession.InvokeMethod(InnerCimInstance, "JoinDomainOrWorkgroup", parameters); return((System.UInt32)result.ReturnValue.Value); }
public (System.UInt32 retval, IEnumerable <MSFTNetConSecRule> outOutput) SetPolicyDelta(System.UInt16?inAction, System.UInt16?inEndpointType, System.String[] inIPv4Addresses, System.String[] inIPv6Addresses, System.Boolean?inPassThru) { var parameters = new CimMethodParametersCollection(); if (inAction.HasValue) { parameters.Add(CimMethodParameter.Create("Action", inAction.Value, CimFlags.None)); } if (inEndpointType.HasValue) { parameters.Add(CimMethodParameter.Create("EndpointType", inEndpointType.Value, CimFlags.None)); } if (inIPv4Addresses != null) { parameters.Add(CimMethodParameter.Create("IPv4Addresses", inIPv4Addresses, CimType.StringArray, inIPv4Addresses == null ? CimFlags.NullValue : CimFlags.None)); } if (inIPv6Addresses != null) { parameters.Add(CimMethodParameter.Create("IPv6Addresses", inIPv6Addresses, CimType.StringArray, inIPv6Addresses == null ? CimFlags.NullValue : CimFlags.None)); } if (inPassThru.HasValue) { parameters.Add(CimMethodParameter.Create("PassThru", inPassThru.Value, CimFlags.None)); } var result = InfrastuctureObjectScope.CimSession.InvokeMethod(InnerCimInstance, "SetPolicyDelta", parameters); return((System.UInt32)result.ReturnValue.Value, (IEnumerable <MSFTNetConSecRule>)InfrastuctureObjectScope.Mapper.CreateMany <MSFTNetConSecRule>(InfrastuctureObjectScope, (IEnumerable <CimInstance>)result.OutParameters["Output"].Value)); }
public (System.UInt32 retval, IEnumerable <MSFTNetSecDeltaCollection> outOutput) SyncPolicyDelta(System.UInt16?inAddressType, System.String[] inDnsServers, System.String[] inDomains, System.UInt16?inEndpointType, System.String[] inServers) { var parameters = new CimMethodParametersCollection(); if (inAddressType.HasValue) { parameters.Add(CimMethodParameter.Create("AddressType", inAddressType.Value, CimFlags.None)); } if (inDnsServers != null) { parameters.Add(CimMethodParameter.Create("DnsServers", inDnsServers, CimType.StringArray, inDnsServers == null ? CimFlags.NullValue : CimFlags.None)); } if (inDomains != null) { parameters.Add(CimMethodParameter.Create("Domains", inDomains, CimType.StringArray, inDomains == null ? CimFlags.NullValue : CimFlags.None)); } if (inEndpointType.HasValue) { parameters.Add(CimMethodParameter.Create("EndpointType", inEndpointType.Value, CimFlags.None)); } if (inServers != null) { parameters.Add(CimMethodParameter.Create("Servers", inServers, CimType.StringArray, inServers == null ? CimFlags.NullValue : CimFlags.None)); } var result = InfrastuctureObjectScope.CimSession.InvokeMethod(InnerCimInstance, "SyncPolicyDelta", parameters); return((System.UInt32)result.ReturnValue.Value, (IEnumerable <MSFTNetSecDeltaCollection>)InfrastuctureObjectScope.Mapper.CreateMany <MSFTNetSecDeltaCollection>(InfrastuctureObjectScope, (IEnumerable <CimInstance>)result.OutParameters["Output"].Value)); }
public (System.UInt32 retval, System.Boolean?outIsMigratable) CheckVirtualSystemIsMigratableToHost(CIMComputerSystem inComputerSystem, System.String inDestinationHost, System.String inMigrationSettingData, System.String[] inNewResourceSettingData, System.String inNewSystemSettingData) { var parameters = new CimMethodParametersCollection(); if (inComputerSystem != null) { parameters.Add(CimMethodParameter.Create("ComputerSystem", inComputerSystem.AsCimInstance(), CimType.Reference, inComputerSystem == null ? CimFlags.NullValue : CimFlags.None)); } if (inDestinationHost != null) { parameters.Add(CimMethodParameter.Create("DestinationHost", inDestinationHost, CimType.String, inDestinationHost == null ? CimFlags.NullValue : CimFlags.None)); } if (inMigrationSettingData != null) { parameters.Add(CimMethodParameter.Create("MigrationSettingData", inMigrationSettingData, CimType.String, inMigrationSettingData == null ? CimFlags.NullValue : CimFlags.None)); } if (inNewResourceSettingData != null) { parameters.Add(CimMethodParameter.Create("NewResourceSettingData", inNewResourceSettingData, CimType.StringArray, inNewResourceSettingData == null ? CimFlags.NullValue : CimFlags.None)); } if (inNewSystemSettingData != null) { parameters.Add(CimMethodParameter.Create("NewSystemSettingData", inNewSystemSettingData, CimType.String, inNewSystemSettingData == null ? CimFlags.NullValue : CimFlags.None)); } var result = InfrastuctureObjectScope.CimSession.InvokeMethod(InnerCimInstance, "CheckVirtualSystemIsMigratableToHost", parameters); return((System.UInt32)result.ReturnValue.Value, (System.Boolean? )result.OutParameters["IsMigratable"].Value); }
public (System.UInt32 retval, MSFTNCSIPolicyConfiguration outOutputObject) Reset(System.Boolean?inCorporateDNSProbeHostAddress, System.Boolean?inCorporateDNSProbeHostName, System.Boolean?inCorporateSitePrefixList, System.Boolean?inCorporateWebsiteProbeURL, System.Boolean?inDomainLocationDeterminationURL, System.Boolean?inPassThru) { var parameters = new CimMethodParametersCollection(); if (inCorporateDNSProbeHostAddress.HasValue) { parameters.Add(CimMethodParameter.Create("CorporateDNSProbeHostAddress", inCorporateDNSProbeHostAddress.Value, CimFlags.None)); } if (inCorporateDNSProbeHostName.HasValue) { parameters.Add(CimMethodParameter.Create("CorporateDNSProbeHostName", inCorporateDNSProbeHostName.Value, CimFlags.None)); } if (inCorporateSitePrefixList.HasValue) { parameters.Add(CimMethodParameter.Create("CorporateSitePrefixList", inCorporateSitePrefixList.Value, CimFlags.None)); } if (inCorporateWebsiteProbeURL.HasValue) { parameters.Add(CimMethodParameter.Create("CorporateWebsiteProbeURL", inCorporateWebsiteProbeURL.Value, CimFlags.None)); } if (inDomainLocationDeterminationURL.HasValue) { parameters.Add(CimMethodParameter.Create("DomainLocationDeterminationURL", inDomainLocationDeterminationURL.Value, CimFlags.None)); } if (inPassThru.HasValue) { parameters.Add(CimMethodParameter.Create("PassThru", inPassThru.Value, CimFlags.None)); } var result = InfrastuctureObjectScope.CimSession.InvokeMethod(InnerCimInstance, "Reset", parameters); return((System.UInt32)result.ReturnValue.Value, (MSFTNCSIPolicyConfiguration)InfrastuctureObjectScope.Mapper.Create(InfrastuctureObjectScope, (CimInstance)result.OutParameters["OutputObject"].Value)); }
public (System.UInt32 retval, System.UInt32?outJobId) Create(System.String inCommand, System.UInt32?inDaysOfMonth, System.UInt32?inDaysOfWeek, System.Boolean?inInteractWithDesktop, System.Boolean?inRunRepeatedly, System.DateTime?inStartTime) { var parameters = new CimMethodParametersCollection(); if (inCommand != null) { parameters.Add(CimMethodParameter.Create("Command", inCommand, CimType.String, inCommand == null ? CimFlags.NullValue : CimFlags.None)); } if (inDaysOfMonth.HasValue) { parameters.Add(CimMethodParameter.Create("DaysOfMonth", inDaysOfMonth.Value, CimFlags.None)); } if (inDaysOfWeek.HasValue) { parameters.Add(CimMethodParameter.Create("DaysOfWeek", inDaysOfWeek.Value, CimFlags.None)); } if (inInteractWithDesktop.HasValue) { parameters.Add(CimMethodParameter.Create("InteractWithDesktop", inInteractWithDesktop.Value, CimFlags.None)); } if (inRunRepeatedly.HasValue) { parameters.Add(CimMethodParameter.Create("RunRepeatedly", inRunRepeatedly.Value, CimFlags.None)); } if (inStartTime.HasValue) { parameters.Add(CimMethodParameter.Create("StartTime", inStartTime.Value, CimFlags.None)); } var result = InfrastuctureObjectScope.CimSession.InvokeMethod(InnerCimInstance, "Create", parameters); return((System.UInt32)result.ReturnValue.Value, (System.UInt32? )result.OutParameters["JobId"].Value); }
public System.UInt32 Load(System.String inLocale, System.String inNamespace, System.String inprovider, System.String inTransactionIdentifier, System.String inUser) { var parameters = new CimMethodParametersCollection(); if (inLocale != null) { parameters.Add(CimMethodParameter.Create("Locale", inLocale, CimType.String, inLocale == null ? CimFlags.NullValue : CimFlags.None)); } if (inNamespace != null) { parameters.Add(CimMethodParameter.Create("Namespace", inNamespace, CimType.String, inNamespace == null ? CimFlags.NullValue : CimFlags.None)); } if (inprovider != null) { parameters.Add(CimMethodParameter.Create("provider", inprovider, CimType.String, inprovider == null ? CimFlags.NullValue : CimFlags.None)); } if (inTransactionIdentifier != null) { parameters.Add(CimMethodParameter.Create("TransactionIdentifier", inTransactionIdentifier, CimType.String, inTransactionIdentifier == null ? CimFlags.NullValue : CimFlags.None)); } if (inUser != null) { parameters.Add(CimMethodParameter.Create("User", inUser, CimType.String, inUser == null ? CimFlags.NullValue : CimFlags.None)); } var result = InfrastuctureObjectScope.CimSession.InvokeMethod(InnerCimInstance, "Load", parameters); return((System.UInt32)result.ReturnValue.Value); }
public (System.UInt32 retval, System.UInt64[] outChangedByteLengths, System.UInt64[] outChangedByteOffsets, CIMConcreteJob outJob, System.UInt64?outProcessedByteLength) GetVirtualDiskChanges(System.UInt64?inByteLength, System.UInt64?inByteOffset, System.String inLimitId, System.String inPath, System.String inTargetSnapshotId) { var parameters = new CimMethodParametersCollection(); if (inByteLength.HasValue) { parameters.Add(CimMethodParameter.Create("ByteLength", inByteLength.Value, CimFlags.None)); } if (inByteOffset.HasValue) { parameters.Add(CimMethodParameter.Create("ByteOffset", inByteOffset.Value, CimFlags.None)); } if (inLimitId != null) { parameters.Add(CimMethodParameter.Create("LimitId", inLimitId, CimType.String, inLimitId == null ? CimFlags.NullValue : CimFlags.None)); } if (inPath != null) { parameters.Add(CimMethodParameter.Create("Path", inPath, CimType.String, inPath == null ? CimFlags.NullValue : CimFlags.None)); } if (inTargetSnapshotId != null) { parameters.Add(CimMethodParameter.Create("TargetSnapshotId", inTargetSnapshotId, CimType.String, inTargetSnapshotId == null ? CimFlags.NullValue : CimFlags.None)); } var result = InfrastuctureObjectScope.CimSession.InvokeMethod(InnerCimInstance, "GetVirtualDiskChanges", parameters); return((System.UInt32)result.ReturnValue.Value, (System.UInt64[])result.OutParameters["ChangedByteLengths"].Value, (System.UInt64[])result.OutParameters["ChangedByteOffsets"].Value, (CIMConcreteJob)InfrastuctureObjectScope.Mapper.Create(InfrastuctureObjectScope, (CimInstance)result.OutParameters["Job"].Value), (System.UInt64? )result.OutParameters["ProcessedByteLength"].Value); }
public System.UInt32 Chkdsk(System.Boolean?inFixErrors, System.Boolean?inForceDismount, System.Boolean?inOkToRunAtBootUp, System.Boolean?inRecoverBadSectors, System.Boolean?inSkipFolderCycle, System.Boolean?inVigorousIndexCheck) { var parameters = new CimMethodParametersCollection(); if (inFixErrors.HasValue) { parameters.Add(CimMethodParameter.Create("FixErrors", inFixErrors.Value, CimFlags.None)); } if (inForceDismount.HasValue) { parameters.Add(CimMethodParameter.Create("ForceDismount", inForceDismount.Value, CimFlags.None)); } if (inOkToRunAtBootUp.HasValue) { parameters.Add(CimMethodParameter.Create("OkToRunAtBootUp", inOkToRunAtBootUp.Value, CimFlags.None)); } if (inRecoverBadSectors.HasValue) { parameters.Add(CimMethodParameter.Create("RecoverBadSectors", inRecoverBadSectors.Value, CimFlags.None)); } if (inSkipFolderCycle.HasValue) { parameters.Add(CimMethodParameter.Create("SkipFolderCycle", inSkipFolderCycle.Value, CimFlags.None)); } if (inVigorousIndexCheck.HasValue) { parameters.Add(CimMethodParameter.Create("VigorousIndexCheck", inVigorousIndexCheck.Value, CimFlags.None)); } var result = InfrastuctureObjectScope.CimSession.InvokeMethod(InnerCimInstance, "Chkdsk", parameters); return((System.UInt32)result.ReturnValue.Value); }
public CimMethodParametersCollection GetParametersForMethod(string NameSpace, string ClassName, string MethodName) { // Returns all In parameters for a given method. Note: Out parameters are not output as this will result in errors when a query is run. CimMethodParametersCollection CimParams = new CimMethodParametersCollection(); CimClass cimClass = SystemSession.GetClass(NameSpace, ClassName); foreach (CimMethodDeclaration CimMDItem in cimClass.CimClassMethods) { if (CimMDItem.Name == MethodName) { foreach (var ParaItem in CimMDItem.Parameters) { bool isInParam = false; foreach (var Qitem in ParaItem.Qualifiers) { if (Qitem.Name.ToLower() == "in") { isInParam = true; } } if (isInParam) { CimParams.Add(CimMethodParameter.Create(ParaItem.Name, null, ParaItem.CimType, CimFlags.In)); } } } } return(CimParams); }
public System.UInt32 Format(System.UInt32?inClusterSize, System.Boolean?inEnableCompression, System.String inFileSystem, System.String inLabel, System.Boolean?inQuickFormat, System.UInt32?inVersion) { var parameters = new CimMethodParametersCollection(); if (inClusterSize.HasValue) { parameters.Add(CimMethodParameter.Create("ClusterSize", inClusterSize.Value, CimFlags.None)); } if (inEnableCompression.HasValue) { parameters.Add(CimMethodParameter.Create("EnableCompression", inEnableCompression.Value, CimFlags.None)); } if (inFileSystem != null) { parameters.Add(CimMethodParameter.Create("FileSystem", inFileSystem, CimType.String, inFileSystem == null ? CimFlags.NullValue : CimFlags.None)); } if (inLabel != null) { parameters.Add(CimMethodParameter.Create("Label", inLabel, CimType.String, inLabel == null ? CimFlags.NullValue : CimFlags.None)); } if (inQuickFormat.HasValue) { parameters.Add(CimMethodParameter.Create("QuickFormat", inQuickFormat.Value, CimFlags.None)); } if (inVersion.HasValue) { parameters.Add(CimMethodParameter.Create("Version", inVersion.Value, CimFlags.None)); } var result = InfrastuctureObjectScope.CimSession.InvokeMethod(InnerCimInstance, "Format", parameters); return((System.UInt32)result.ReturnValue.Value); }
public (System.UInt32 retval, CIMConcreteJob outJob, CIMComputerSystem outNewComputerSystem) MigrateVirtualSystemToSystem(CIMComputerSystem inComputerSystem, CIMSystem inDestinationSystem, System.String inMigrationSettingData, System.String[] inNewResourceSettingData, System.String inNewSystemSettingData) { var parameters = new CimMethodParametersCollection(); if (inComputerSystem != null) { parameters.Add(CimMethodParameter.Create("ComputerSystem", inComputerSystem.AsCimInstance(), CimType.Reference, inComputerSystem == null ? CimFlags.NullValue : CimFlags.None)); } if (inDestinationSystem != null) { parameters.Add(CimMethodParameter.Create("DestinationSystem", inDestinationSystem.AsCimInstance(), CimType.Reference, inDestinationSystem == null ? CimFlags.NullValue : CimFlags.None)); } if (inMigrationSettingData != null) { parameters.Add(CimMethodParameter.Create("MigrationSettingData", inMigrationSettingData, CimType.String, inMigrationSettingData == null ? CimFlags.NullValue : CimFlags.None)); } if (inNewResourceSettingData != null) { parameters.Add(CimMethodParameter.Create("NewResourceSettingData", inNewResourceSettingData, CimType.StringArray, inNewResourceSettingData == null ? CimFlags.NullValue : CimFlags.None)); } if (inNewSystemSettingData != null) { parameters.Add(CimMethodParameter.Create("NewSystemSettingData", inNewSystemSettingData, CimType.String, inNewSystemSettingData == null ? CimFlags.NullValue : CimFlags.None)); } var result = InfrastuctureObjectScope.CimSession.InvokeMethod(InnerCimInstance, "MigrateVirtualSystemToSystem", parameters); return((System.UInt32)result.ReturnValue.Value, (CIMConcreteJob)InfrastuctureObjectScope.Mapper.Create(InfrastuctureObjectScope, (CimInstance)result.OutParameters["Job"].Value), (CIMComputerSystem)InfrastuctureObjectScope.Mapper.Create(InfrastuctureObjectScope, (CimInstance)result.OutParameters["NewComputerSystem"].Value)); }
public (System.UInt32 retval, IEnumerable <MSFTNetPrefixPolicy> outCmdletOutput) Create(System.UInt32?inLabel, System.Boolean?inPassThru, System.String inPolicyStore, System.UInt32?inPrecedence, System.String inPrefix) { var parameters = new CimMethodParametersCollection(); if (inLabel.HasValue) { parameters.Add(CimMethodParameter.Create("Label", inLabel.Value, CimFlags.None)); } if (inPassThru.HasValue) { parameters.Add(CimMethodParameter.Create("PassThru", inPassThru.Value, CimFlags.None)); } if (inPolicyStore != null) { parameters.Add(CimMethodParameter.Create("PolicyStore", inPolicyStore, CimType.String, inPolicyStore == null ? CimFlags.NullValue : CimFlags.None)); } if (inPrecedence.HasValue) { parameters.Add(CimMethodParameter.Create("Precedence", inPrecedence.Value, CimFlags.None)); } if (inPrefix != null) { parameters.Add(CimMethodParameter.Create("Prefix", inPrefix, CimType.String, inPrefix == null ? CimFlags.NullValue : CimFlags.None)); } var result = InfrastuctureObjectScope.CimSession.InvokeMethod(InnerCimInstance, "Create", parameters); return((System.UInt32)result.ReturnValue.Value, (IEnumerable <MSFTNetPrefixPolicy>)InfrastuctureObjectScope.Mapper.CreateMany <MSFTNetPrefixPolicy>(InfrastuctureObjectScope, (IEnumerable <CimInstance>)result.OutParameters["CmdletOutput"].Value)); }
public (System.UInt32 retval, MSFTDAClientExperienceConfiguration outOutputObject) Reset(System.Boolean?inCorporateResources, System.Boolean?inCustomCommands, System.Boolean?inForceTunneling, System.Boolean?inFriendlyName, System.Boolean?inGslbFqdn, System.Boolean?inIPsecTunnelEndpoints, System.Boolean?inManualEntryPointSelectionAllowed, System.Boolean?inPassiveMode, System.Boolean?inPassThru, System.Boolean?inPreferLocalNamesAllowed, System.Boolean?inSupportEmail, System.Boolean?inUserInterface) { var parameters = new CimMethodParametersCollection(); if (inCorporateResources.HasValue) { parameters.Add(CimMethodParameter.Create("CorporateResources", inCorporateResources.Value, CimFlags.None)); } if (inCustomCommands.HasValue) { parameters.Add(CimMethodParameter.Create("CustomCommands", inCustomCommands.Value, CimFlags.None)); } if (inForceTunneling.HasValue) { parameters.Add(CimMethodParameter.Create("ForceTunneling", inForceTunneling.Value, CimFlags.None)); } if (inFriendlyName.HasValue) { parameters.Add(CimMethodParameter.Create("FriendlyName", inFriendlyName.Value, CimFlags.None)); } if (inGslbFqdn.HasValue) { parameters.Add(CimMethodParameter.Create("GslbFqdn", inGslbFqdn.Value, CimFlags.None)); } if (inIPsecTunnelEndpoints.HasValue) { parameters.Add(CimMethodParameter.Create("IPsecTunnelEndpoints", inIPsecTunnelEndpoints.Value, CimFlags.None)); } if (inManualEntryPointSelectionAllowed.HasValue) { parameters.Add(CimMethodParameter.Create("ManualEntryPointSelectionAllowed", inManualEntryPointSelectionAllowed.Value, CimFlags.None)); } if (inPassiveMode.HasValue) { parameters.Add(CimMethodParameter.Create("PassiveMode", inPassiveMode.Value, CimFlags.None)); } if (inPassThru.HasValue) { parameters.Add(CimMethodParameter.Create("PassThru", inPassThru.Value, CimFlags.None)); } if (inPreferLocalNamesAllowed.HasValue) { parameters.Add(CimMethodParameter.Create("PreferLocalNamesAllowed", inPreferLocalNamesAllowed.Value, CimFlags.None)); } if (inSupportEmail.HasValue) { parameters.Add(CimMethodParameter.Create("SupportEmail", inSupportEmail.Value, CimFlags.None)); } if (inUserInterface.HasValue) { parameters.Add(CimMethodParameter.Create("UserInterface", inUserInterface.Value, CimFlags.None)); } var result = InfrastuctureObjectScope.CimSession.InvokeMethod(InnerCimInstance, "Reset", parameters); return((System.UInt32)result.ReturnValue.Value, (MSFTDAClientExperienceConfiguration)InfrastuctureObjectScope.Mapper.Create(InfrastuctureObjectScope, (CimInstance)result.OutParameters["OutputObject"].Value)); }
public System.UInt32 Create(System.Boolean?inDesktopInteract, System.String inDisplayName, System.Byte?inErrorControl, System.String inLoadOrderGroup, System.String[] inLoadOrderGroupDependencies, System.String inName, System.String inPathName, System.String[] inServiceDependencies, System.Byte?inServiceType, System.String inStartMode, System.String inStartName, System.String inStartPassword) { var parameters = new CimMethodParametersCollection(); if (inDesktopInteract.HasValue) { parameters.Add(CimMethodParameter.Create("DesktopInteract", inDesktopInteract.Value, CimFlags.None)); } if (inDisplayName != null) { parameters.Add(CimMethodParameter.Create("DisplayName", inDisplayName, CimType.String, inDisplayName == null ? CimFlags.NullValue : CimFlags.None)); } if (inErrorControl.HasValue) { parameters.Add(CimMethodParameter.Create("ErrorControl", inErrorControl.Value, CimFlags.None)); } if (inLoadOrderGroup != null) { parameters.Add(CimMethodParameter.Create("LoadOrderGroup", inLoadOrderGroup, CimType.String, inLoadOrderGroup == null ? CimFlags.NullValue : CimFlags.None)); } if (inLoadOrderGroupDependencies != null) { parameters.Add(CimMethodParameter.Create("LoadOrderGroupDependencies", inLoadOrderGroupDependencies, CimType.StringArray, inLoadOrderGroupDependencies == null ? CimFlags.NullValue : CimFlags.None)); } if (inName != null) { parameters.Add(CimMethodParameter.Create("Name", inName, CimType.String, inName == null ? CimFlags.NullValue : CimFlags.None)); } if (inPathName != null) { parameters.Add(CimMethodParameter.Create("PathName", inPathName, CimType.String, inPathName == null ? CimFlags.NullValue : CimFlags.None)); } if (inServiceDependencies != null) { parameters.Add(CimMethodParameter.Create("ServiceDependencies", inServiceDependencies, CimType.StringArray, inServiceDependencies == null ? CimFlags.NullValue : CimFlags.None)); } if (inServiceType.HasValue) { parameters.Add(CimMethodParameter.Create("ServiceType", inServiceType.Value, CimFlags.None)); } if (inStartMode != null) { parameters.Add(CimMethodParameter.Create("StartMode", inStartMode, CimType.String, inStartMode == null ? CimFlags.NullValue : CimFlags.None)); } if (inStartName != null) { parameters.Add(CimMethodParameter.Create("StartName", inStartName, CimType.String, inStartName == null ? CimFlags.NullValue : CimFlags.None)); } if (inStartPassword != null) { parameters.Add(CimMethodParameter.Create("StartPassword", inStartPassword, CimType.String, inStartPassword == null ? CimFlags.NullValue : CimFlags.None)); } var result = InfrastuctureObjectScope.CimSession.InvokeMethod(InnerCimInstance, "Create", parameters); return((System.UInt32)result.ReturnValue.Value); }
internal CimMethodParametersCollection GetCimMethodParametersCollection() { CimMethodParametersCollection cimMethodParametersCollection = new CimMethodParametersCollection(); foreach (MethodParameter methodInputParameter in base.GetMethodInputParameters()) { CimMethodParameter cimMethodParameter = CimMethodParameter.Create(methodInputParameter.Name, methodInputParameter.Value, CimValueConverter.GetCimTypeEnum(methodInputParameter.ParameterType), (CimFlags)((long)0)); cimMethodParametersCollection.Add(cimMethodParameter); } return(cimMethodParametersCollection); }
public System.UInt32 WriteByPrinterNfcTag(MSFTPrinterNfcTag inInputObject) { var parameters = new CimMethodParametersCollection(); if (inInputObject != null) { parameters.Add(CimMethodParameter.Create("InputObject", inInputObject.AsCimInstance(), CimType.Instance, inInputObject == null ? CimFlags.NullValue : CimFlags.None)); } var result = InfrastuctureObjectScope.CimSession.InvokeMethod(InnerCimInstance, "WriteByPrinterNfcTag", parameters); return((System.UInt32)result.ReturnValue.Value); }
public (System.UInt32 retval, CIMConcreteJob outJob) ModifyServiceSettings(System.String inSettingData) { var parameters = new CimMethodParametersCollection(); if (inSettingData != null) { parameters.Add(CimMethodParameter.Create("SettingData", inSettingData, CimType.String, inSettingData == null ? CimFlags.NullValue : CimFlags.None)); } var result = InfrastuctureObjectScope.CimSession.InvokeMethod(InnerCimInstance, "ModifyServiceSettings", parameters); return((System.UInt32)result.ReturnValue.Value, (CIMConcreteJob)InfrastuctureObjectScope.Mapper.Create(InfrastuctureObjectScope, (CimInstance)result.OutParameters["Job"].Value)); }
public System.UInt32 ResetCounter(System.UInt16?inSelectedCounter) { var parameters = new CimMethodParametersCollection(); if (inSelectedCounter.HasValue) { parameters.Add(CimMethodParameter.Create("SelectedCounter", inSelectedCounter.Value, CimFlags.None)); } var result = InfrastuctureObjectScope.CimSession.InvokeMethod(InnerCimInstance, "ResetCounter", parameters); return((System.UInt32)result.ReturnValue.Value); }
public System.UInt32 Rename(System.String inName) { var parameters = new CimMethodParametersCollection(); if (inName != null) { parameters.Add(CimMethodParameter.Create("Name", inName, CimType.String, inName == null ? CimFlags.NullValue : CimFlags.None)); } var result = InfrastuctureObjectScope.CimSession.InvokeMethod(InnerCimInstance, "Rename", parameters); return((System.UInt32)result.ReturnValue.Value); }
public (System.UInt32 retval, CIMConcreteJob outJob) RemoveAuthorizationEntry(System.String inAllowedPrimaryHostSystem) { var parameters = new CimMethodParametersCollection(); if (inAllowedPrimaryHostSystem != null) { parameters.Add(CimMethodParameter.Create("AllowedPrimaryHostSystem", inAllowedPrimaryHostSystem, CimType.String, inAllowedPrimaryHostSystem == null ? CimFlags.NullValue : CimFlags.None)); } var result = InfrastuctureObjectScope.CimSession.InvokeMethod(InnerCimInstance, "RemoveAuthorizationEntry", parameters); return((System.UInt32)result.ReturnValue.Value, (CIMConcreteJob)InfrastuctureObjectScope.Mapper.Create(InfrastuctureObjectScope, (CimInstance)result.OutParameters["Job"].Value)); }
public (System.UInt32 retval, CIMConcreteJob outJob) ResetReplicationStatistics(CIMComputerSystem inComputerSystem) { var parameters = new CimMethodParametersCollection(); if (inComputerSystem != null) { parameters.Add(CimMethodParameter.Create("ComputerSystem", inComputerSystem.AsCimInstance(), CimType.Reference, inComputerSystem == null ? CimFlags.NullValue : CimFlags.None)); } var result = InfrastuctureObjectScope.CimSession.InvokeMethod(InnerCimInstance, "ResetReplicationStatistics", parameters); return((System.UInt32)result.ReturnValue.Value, (CIMConcreteJob)InfrastuctureObjectScope.Mapper.Create(InfrastuctureObjectScope, (CimInstance)result.OutParameters["Job"].Value)); }