mirror of
https://github.com/PowerShell/PowerShell
synced 2026-06-08 12:12:50 +00:00
Add missing XML doc elements for methods in RunspaceFactory (#18450)
This commit is contained in:
@@ -476,58 +476,64 @@ namespace System.Management.Automation.Runspaces
|
||||
#region Runspace - Remote Factory
|
||||
|
||||
/// <summary>
|
||||
/// Creates a remote Runspace.
|
||||
/// </summary>
|
||||
/// <param name="connectionInfo">It defines connection path to a remote runspace that needs to be created.</param>
|
||||
/// <param name="host">The explicit PSHost implementation.</param>
|
||||
/// <param name="typeTable">
|
||||
/// The TypeTable to use while deserializing/serializing remote objects.
|
||||
/// TypeTable has the following information used by serializer:
|
||||
/// 1. SerializationMethod
|
||||
/// 2. SerializationDepth
|
||||
/// 3. SpecificSerializationProperties
|
||||
///
|
||||
/// TypeTable has the following information used by deserializer:
|
||||
/// 1. TargetTypeForDeserialization
|
||||
/// 2. TypeConverter
|
||||
/// </param>
|
||||
/// <param name="host"></param>
|
||||
/// <param name="connectionInfo"></param>
|
||||
/// <returns></returns>
|
||||
/// <returns>A remote Runspace.</returns>
|
||||
public static Runspace CreateRunspace(RunspaceConnectionInfo connectionInfo, PSHost host, TypeTable typeTable)
|
||||
{
|
||||
return CreateRunspace(connectionInfo, host, typeTable, null, null);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Creates a remote Runspace.
|
||||
/// </summary>
|
||||
/// <param name="connectionInfo">It defines connection path to a remote runspace that needs to be created.</param>
|
||||
/// <param name="host">The explicit PSHost implementation.</param>
|
||||
/// <param name="typeTable">
|
||||
/// The TypeTable to use while deserializing/serializing remote objects.
|
||||
/// TypeTable has the following information used by serializer:
|
||||
/// 1. SerializationMethod
|
||||
/// 2. SerializationDepth
|
||||
/// 3. SpecificSerializationProperties
|
||||
///
|
||||
/// TypeTable has the following information used by deserializer:
|
||||
/// 1. TargetTypeForDeserialization
|
||||
/// 2. TypeConverter
|
||||
/// </param>
|
||||
/// <param name="host"></param>
|
||||
/// <param name="connectionInfo"></param>
|
||||
/// <param name="applicationArguments">
|
||||
/// Application arguments the server can see in <see cref="System.Management.Automation.Remoting.PSSenderInfo.ApplicationArguments"/>
|
||||
/// </param>
|
||||
/// <returns></returns>
|
||||
/// <returns>A remote Runspace.</returns>
|
||||
public static Runspace CreateRunspace(RunspaceConnectionInfo connectionInfo, PSHost host, TypeTable typeTable, PSPrimitiveDictionary applicationArguments)
|
||||
{
|
||||
return CreateRunspace(connectionInfo, host, typeTable, applicationArguments, null);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Creates a remote Runspace.
|
||||
/// </summary>
|
||||
/// <param name="connectionInfo"></param>
|
||||
/// <param name="host"></param>
|
||||
/// <param name="connectionInfo">It defines connection path to a remote runspace that needs to be created.</param>
|
||||
/// <param name="host">The explicit PSHost implementation.</param>
|
||||
/// <param name="typeTable">
|
||||
/// The TypeTable to use while deserializing/serializing remote objects.
|
||||
/// TypeTable has the following information used by serializer:
|
||||
/// 1. SerializationMethod
|
||||
/// 2. SerializationDepth
|
||||
/// 3. SpecificSerializationProperties
|
||||
///
|
||||
/// TypeTable has the following information used by deserializer:
|
||||
/// 1. TargetTypeForDeserialization
|
||||
/// 2. TypeConverter
|
||||
@@ -536,7 +542,7 @@ namespace System.Management.Automation.Runspaces
|
||||
/// Application arguments the server can see in <see cref="System.Management.Automation.Remoting.PSSenderInfo.ApplicationArguments"/>
|
||||
/// </param>
|
||||
/// <param name="name">Name for remote runspace.</param>
|
||||
/// <returns></returns>
|
||||
/// <returns>A remote Runspace.</returns>
|
||||
public static Runspace CreateRunspace(RunspaceConnectionInfo connectionInfo, PSHost host, TypeTable typeTable, PSPrimitiveDictionary applicationArguments, string name)
|
||||
{
|
||||
if (connectionInfo is WSManConnectionInfo)
|
||||
@@ -548,19 +554,21 @@ namespace System.Management.Automation.Runspaces
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Creates a remote Runspace.
|
||||
/// </summary>
|
||||
/// <param name="host"></param>
|
||||
/// <param name="connectionInfo"></param>
|
||||
/// <returns></returns>
|
||||
/// <param name="host">The explicit PSHost implementation.</param>
|
||||
/// <param name="connectionInfo">It defines connection path to a remote runspace that needs to be created.</param>
|
||||
/// <returns>A remote Runspace.</returns>
|
||||
public static Runspace CreateRunspace(PSHost host, RunspaceConnectionInfo connectionInfo)
|
||||
{
|
||||
return CreateRunspace(connectionInfo, host, null);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Creates a remote Runspace.
|
||||
/// </summary>
|
||||
/// <param name="connectionInfo"></param>
|
||||
/// <returns></returns>
|
||||
/// <param name="connectionInfo">It defines connection path to a remote runspace that needs to be created.</param>
|
||||
/// <returns>A remote Runspace.</returns>
|
||||
public static Runspace CreateRunspace(RunspaceConnectionInfo connectionInfo)
|
||||
{
|
||||
return CreateRunspace(null, connectionInfo);
|
||||
@@ -571,9 +579,20 @@ namespace System.Management.Automation.Runspaces
|
||||
#region V3 Extensions
|
||||
|
||||
/// <summary>
|
||||
/// Creates an out-of-process remote Runspace.
|
||||
/// </summary>
|
||||
/// <param name="typeTable"></param>
|
||||
/// <returns></returns>
|
||||
/// <param name="typeTable">
|
||||
/// The TypeTable to use while deserializing/serializing remote objects.
|
||||
/// TypeTable has the following information used by serializer:
|
||||
/// 1. SerializationMethod
|
||||
/// 2. SerializationDepth
|
||||
/// 3. SpecificSerializationProperties
|
||||
///
|
||||
/// TypeTable has the following information used by deserializer:
|
||||
/// 1. TargetTypeForDeserialization
|
||||
/// 2. TypeConverter
|
||||
/// </param>
|
||||
/// <returns>An out-of-process remote Runspace.</returns>
|
||||
public static Runspace CreateOutOfProcessRunspace(TypeTable typeTable)
|
||||
{
|
||||
NewProcessConnectionInfo connectionInfo = new NewProcessConnectionInfo(null);
|
||||
@@ -582,10 +601,21 @@ namespace System.Management.Automation.Runspaces
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Creates an out-of-process remote Runspace.
|
||||
/// </summary>
|
||||
/// <param name="typeTable"></param>
|
||||
/// <param name="processInstance"></param>
|
||||
/// <returns></returns>
|
||||
/// <param name="typeTable">
|
||||
/// The TypeTable to use while deserializing/serializing remote objects.
|
||||
/// TypeTable has the following information used by serializer:
|
||||
/// 1. SerializationMethod
|
||||
/// 2. SerializationDepth
|
||||
/// 3. SpecificSerializationProperties
|
||||
///
|
||||
/// TypeTable has the following information used by deserializer:
|
||||
/// 1. TargetTypeForDeserialization
|
||||
/// 2. TypeConverter
|
||||
/// </param>
|
||||
/// <param name="processInstance">It represents a PowerShell process that is used for an out-of-process remote Runspace</param>
|
||||
/// <returns>An out-of-process remote Runspace.</returns>
|
||||
public static Runspace CreateOutOfProcessRunspace(TypeTable typeTable, PowerShellProcessInstance processInstance)
|
||||
{
|
||||
NewProcessConnectionInfo connectionInfo = new NewProcessConnectionInfo(null) { Process = processInstance };
|
||||
|
||||
@@ -11,6 +11,7 @@ using System.Text;
|
||||
namespace System.Management.Automation.Runspaces
|
||||
{
|
||||
/// <summary>
|
||||
/// This class represents a PowerShell process that is used for an out-of-process remote Runspace.
|
||||
/// </summary>
|
||||
public sealed class PowerShellProcessInstance : IDisposable
|
||||
{
|
||||
@@ -30,8 +31,6 @@ namespace System.Management.Automation.Runspaces
|
||||
|
||||
#region Constructors
|
||||
|
||||
/// <summary>
|
||||
/// </summary>
|
||||
static PowerShellProcessInstance()
|
||||
{
|
||||
#if UNIX
|
||||
@@ -145,10 +144,10 @@ namespace System.Management.Automation.Runspaces
|
||||
/// <summary>
|
||||
/// Initializes a new instance of the <see cref="PowerShellProcessInstance"/> class. Initializes the underlying dotnet process class.
|
||||
/// </summary>
|
||||
/// <param name="powerShellVersion"></param>
|
||||
/// <param name="credential"></param>
|
||||
/// <param name="initializationScript"></param>
|
||||
/// <param name="useWow64"></param>
|
||||
/// <param name="powerShellVersion">Specifies the version of powershell.</param>
|
||||
/// <param name="credential">Specifies a user account credentials.</param>
|
||||
/// <param name="initializationScript">Specifies a script that will be executed when the powershell process is initialized.</param>
|
||||
/// <param name="useWow64">Specifies if the powershell process will be 32-bit.</param>
|
||||
public PowerShellProcessInstance(Version powerShellVersion, PSCredential credential, ScriptBlock initializationScript, bool useWow64) : this(powerShellVersion, credential, initializationScript, useWow64, workingDirectory: null)
|
||||
{
|
||||
}
|
||||
@@ -178,7 +177,9 @@ namespace System.Management.Automation.Runspaces
|
||||
#endregion Constructors
|
||||
|
||||
#region Dispose
|
||||
|
||||
/// <summary>
|
||||
/// Implementing the <see cref="IDisposable"/> interface.
|
||||
/// </summary>
|
||||
public void Dispose()
|
||||
{
|
||||
@@ -186,9 +187,6 @@ namespace System.Management.Automation.Runspaces
|
||||
GC.SuppressFinalize(this);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// </summary>
|
||||
/// <param name="disposing"></param>
|
||||
private void Dispose(bool disposing)
|
||||
{
|
||||
if (_isDisposed) return;
|
||||
@@ -220,7 +218,9 @@ namespace System.Management.Automation.Runspaces
|
||||
#endregion Dispose
|
||||
|
||||
#region Public Properties
|
||||
|
||||
/// <summary>
|
||||
/// Gets the process object of the remote target.
|
||||
/// </summary>
|
||||
public Process Process { get; }
|
||||
|
||||
|
||||
Reference in New Issue
Block a user