spelling: comments in src/System.Management.Automation/utils

This commit is contained in:
Josh Soref 2016-08-28 06:01:56 +00:00
parent 777bc2c1a3
commit 45a5f8b7d1
20 changed files with 46 additions and 46 deletions

View file

@ -38,7 +38,7 @@ namespace System.Management.Automation
{
/// <summary>
/// We need it to avoid calling lookups inside dynamic assemblies with PS Types, so we exclude it from GetAssemblies().
/// We use this convention for names to achive it.
/// We use this convention for names to archive it.
/// </summary>
internal static readonly char FIRST_CHAR_PSASSEMBLY_MARK = (char)0x29f9;
@ -326,7 +326,7 @@ namespace System.Management.Automation
}
/// <summary>
/// Load assemlby from byte stream.
/// Load assembly from byte stream.
/// </summary>
internal static Assembly LoadFrom(Stream assembly)
{
@ -602,7 +602,7 @@ namespace System.Management.Automation
///
/// In CORECLR, there are two peculiarities with its implementation that affect our own:
/// 1. Structures cannot be instantiated using GetConstructor, so they must be filtered out.
/// 2. Classes must have a default constructor implemented for GetContructor to work.
/// 2. Classes must have a default constructor implemented for GetConstructor to work.
///
/// See RemoteHostEncoder.IsEncodingAllowedForClassOrStruct for a list of the required types.
/// </summary>

View file

@ -371,7 +371,7 @@ namespace System.Management.Automation.Internal
/// Constructor with inner exception
/// </summary>
/// <param name="message">error message</param>
/// <param name="innerException">innter exception</param>
/// <param name="innerException">inner exception</param>
/// <remarks>This constructor is currently not called
/// explicitly from crypto utils</remarks>
public PSCryptoException(string message, Exception innerException) :
@ -512,7 +512,7 @@ namespace System.Management.Automation.Internal
}
/// <summary>
/// Generates an AEX-256 sessin key if one is not already generated
/// Generates an AEX-256 session key if one is not already generated
/// </summary>
internal void GenerateSessionKey()
{
@ -860,7 +860,7 @@ namespace System.Management.Automation.Internal
#region IDisposable
/// <summary>
/// Dipose resources
/// Dispose resources
/// </summary>
public void Dispose()
{

View file

@ -21,7 +21,7 @@ namespace System.Management.Automation.Internal
/// Microsoft.PowerShell.GraphicalHost.dll contains:
/// 1) out-gridview window implementation (the actual cmdlet is in Microsoft.PowerShell.Commands.Utility.dll)
/// 2) show-command window implementation (the actual cmdlet is in Microsoft.PowerShell.Commands.Utility.dll)
/// 3) the help window used in the System.Management.Automation.dll's get-help cmdslet when -ShowWindow is specified
/// 3) the help window used in the System.Management.Automation.dll's get-help cmdlet when -ShowWindow is specified
/// </summary>
internal class GraphicalHostReflectionWrapper
{

View file

@ -107,7 +107,7 @@ namespace System.Management.Automation.Runspaces
/// If enumerateCollection is true, and <paramref name="obj"/>
/// is an enumeration according to LanguagePrimitives.GetEnumerable,
/// the objects in the enumeration will be unrolled and
/// written seperately. Otherwise, <paramref name="obj"/>
/// written separately. Otherwise, <paramref name="obj"/>
/// will be written as a single object.
/// </param>
/// <returns>The number of objects written</returns>

View file

@ -24,7 +24,7 @@ namespace System.Management.Automation
///
/// The PSTraceSource class is derived from Switch to provide granular
/// control over the tracing in a program. An instance of PSTraceSource
/// is created for each category of tracing such that seperate flags
/// is created for each category of tracing such that separate flags
/// (filters) can be set. Each flag enables one or more method for tracing.
///
/// For instance, the Exception flag will enable tracing on these methods:

View file

@ -280,7 +280,7 @@ namespace System.Management.Automation.Internal
/// If enumerateCollection is true, and <paramref name="obj"/>
/// is an enumeration according to LanguagePrimitives.GetEnumerable,
/// the objects in the enumeration will be unrolled and
/// written seperately. Otherwise, <paramref name="obj"/>
/// written separately. Otherwise, <paramref name="obj"/>
/// will be written as a single object.
/// </param>
/// <returns>The number of objects written</returns>
@ -520,7 +520,7 @@ namespace System.Management.Automation.Internal
/// Default constructor
/// </summary>
/// <remarks>
/// Constructs a stream with a miximum size of Int32.Max
/// Constructs a stream with a maximum size of Int32.Max
/// </remarks>
internal ObjectStream()
: this(Int32.MaxValue)
@ -1293,7 +1293,7 @@ namespace System.Management.Automation.Internal
/// If enumerateCollection is true, and <paramref name="obj"/>
/// is an enumeration according to LanguagePrimitives.GetEnumerable,
/// the objects in the enumeration will be unrolled and
/// written seperately. Otherwise, <paramref name="obj"/>
/// written separately. Otherwise, <paramref name="obj"/>
/// will be written as a single object.
/// </param>
/// <returns>The number of objects written</returns>
@ -1342,7 +1342,7 @@ namespace System.Management.Automation.Internal
foreach (object o in enumerable)
{
// 879023-2003/10/28-JonN
// Outputting stops when recieving a AutomationNull.Value
// Outputting stops when receiving a AutomationNull.Value
// 2003/10/28-JonN There is a window where another
// thread could modify the array to contain
// AutomationNull.Value, but I'm not going to deal with it.
@ -1833,7 +1833,7 @@ namespace System.Management.Automation.Internal
{
foreach (object o in enumerable)
{
// Outputting stops when recieving a AutomationNull.Value
// Outputting stops when receiving a AutomationNull.Value
// There is a window where another thread could modify the
// array to contain AutomationNull.Value,
// but I'm not going to deal with it.

View file

@ -156,7 +156,7 @@ namespace System.Management.Automation.Internal
/// If enumerateCollection is true, and <paramref name="obj"/>
/// is an enumeration according to LanguagePrimitives.GetEnumerable,
/// the objects in the enumeration will be unrolled and
/// written seperately. Otherwise, <paramref name="obj"/>
/// written separately. Otherwise, <paramref name="obj"/>
/// will be written as a single object.
/// </param>
/// <returns>The number of objects written</returns>

View file

@ -23,7 +23,7 @@ namespace System.Management.Automation
/// </summary>
/// <param name="cmdlet">cmdlet that is opening the file (used mainly for error reporting)</param>
/// <param name="filePath">path to the file (as specified on the command line - this method will resolve the path)</param>
/// <param name="encoding">encoding (this method will convert the command line strin to an Encoding instance)</param>
/// <param name="encoding">encoding (this method will convert the command line string to an Encoding instance)</param>
/// <param name="defaultEncoding">if <c>true</c>, then we will use default .NET encoding instead of the encoding specified in <paramref name="encoding"/> parameter</param>
/// <param name="Append"></param>
/// <param name="Force"></param>
@ -57,7 +57,7 @@ namespace System.Management.Automation
/// </summary>
/// <param name="cmdlet">cmdlet that is opening the file (used mainly for error reporting)</param>
/// <param name="filePath">path to the file (as specified on the command line - this method will resolve the path)</param>
/// <param name="resolvedEncoding">encoding (this method will convert the command line strin to an Encoding instance)</param>
/// <param name="resolvedEncoding">encoding (this method will convert the command line string to an Encoding instance)</param>
/// <param name="defaultEncoding">if <c>true</c>, then we will use default .NET encoding instead of the encoding specified in <paramref name="encoding"/> parameter</param>
/// <param name="Append"></param>
/// <param name="Force"></param>
@ -453,7 +453,7 @@ namespace System.Management.Automation
internal const string OEM = "oem";
/// <summary>
/// retrieve the encoding paramater from the command line
/// retrieve the encoding parameter from the command line
/// it throws if the encoding does not match the known ones
/// </summary>
/// <returns>a System.Text.Encoding object (null if no encoding specified)</returns>

View file

@ -350,7 +350,7 @@ namespace System.Management.Automation.Tracing
Exception = 0xB002,
/// <summary>
/// PoweShellObject
/// PowerShellObject
/// </summary>
PowerShellObject = 0xB003,
@ -940,7 +940,7 @@ namespace System.Management.Automation.Tracing
private bool disposed;
/// <summary>
/// Consturctor
/// Constructor
/// </summary>
internal PowerShellTraceSource(PowerShellTraceTask task, PowerShellTraceKeywords keywords)
{

View file

@ -145,10 +145,10 @@ namespace System.Management.Automation
}
}
#if !CORECLR // .NET Frmework Version is not applicable to CoreCLR
#if !CORECLR // .NET Framework Version is not applicable to CoreCLR
/// <summary>
/// Detects the installation of Frmework Versions 1.1, 2.0, 3.0 and 3.5 and 4.0 through
/// the official registry instalation keys.
/// Detects the installation of Framework Versions 1.1, 2.0, 3.0 and 3.5 and 4.0 through
/// the official registry installation keys.
/// </summary>
internal static class FrameworkRegistryInstallation
{
@ -586,7 +586,7 @@ namespace System.Management.Automation
}
#else
// Important:
// this functiona has a clone in Workflow.ServiceCore in admin\monad\src\m3p\product\ServiceCore\WorkflowCore\WorkflowRuntimeCompilation.cs
// this function has a clone in Workflow.ServiceCore in admin\monad\src\m3p\product\ServiceCore\WorkflowCore\WorkflowRuntimeCompilation.cs
// if you are making any changes specific to this function then update the clone as well.
var sysInfo = new NativeMethods.SYSTEM_INFO();
@ -682,7 +682,7 @@ namespace System.Management.Automation
///
/// This method is used when handling a script block that contains $using for Invoke-Command.
///
/// When run Invoke-Command targetting a machine that runs PSv3 or above, we pass a dictionary
/// When run Invoke-Command targeting a machine that runs PSv3 or above, we pass a dictionary
/// to the remote end that contains the key of each UsingExpressionAst and its value. This method
/// is used to generate the key.
/// </summary>

View file

@ -683,7 +683,7 @@ namespace System.Management.Automation
/// SessionStateUnauthorizedAccessException occurs when
/// a change to a session state object cannot be completed
/// because the object is read-only or constant, or because
/// an object which is declard constant cannot be removed
/// an object which is declared constant cannot be removed
/// or made non-constant.
/// </summary>
[Serializable]

View file

@ -36,7 +36,7 @@ namespace System.Management.Automation
/// Constructors will be traced
/// </summary>
/// <!--
/// The TraceConstrutor methods are enabled
/// The TraceConstructor methods are enabled
/// -->
Constructor = 0x00000001,
@ -221,7 +221,7 @@ namespace System.Management.Automation
/// <!--
/// The StructuredTraceSource class is derived from TraceSource to provide granular
/// control over the tracing in a program. An instance of StructuredTraceSource
/// is created for each category of tracing such that seperate flags
/// is created for each category of tracing such that separate flags
/// (filters) can be set. Each flag enables one or more method for tracing.
///
/// For instance, the Exception flag will enable tracing on these methods:

View file

@ -452,7 +452,7 @@ namespace System.Management.Automation
public static class VerbsDiagnostic
{
/// <summary>
/// Interatively interact with a resource or activity for the purpose finding a flaw or better understanding of what is occurring.
/// Iteratively interact with a resource or activity for the purpose finding a flaw or better understanding of what is occurring.
/// </summary>
public const string Debug = "Debug";
@ -509,7 +509,7 @@ namespace System.Management.Automation
public const string Receive = "Receive";
/// <summary>
/// Associate subsequent activies with a resource
/// Associate subsequent activities with a resource
/// </summary>
public const string Connect = "Connect";

View file

@ -653,7 +653,7 @@ namespace System.Management.Automation
/// to a defined exception. If the HRESULT maps to a defined exception, ThrowExceptionForHR
/// creates an instance of the exception and throws it. Otherwise, it creates an instance
/// of System.Runtime.InteropServices.COMException, initializes the error code field with
/// the HRESULT, and throws that exception. When this method is invoked, it attemps to
/// the HRESULT, and throws that exception. When this method is invoked, it attempts to
/// retrieve extra information regarding the error by using the unmanaged GetErrorInfo
/// function.
/// </exception>
@ -772,7 +772,7 @@ namespace System.Management.Automation
/// to a defined exception. If the HRESULT maps to a defined exception, ThrowExceptionForHR
/// creates an instance of the exception and throws it. Otherwise, it creates an instance
/// of System.Runtime.InteropServices.COMException, initializes the error code field with
/// the HRESULT, and throws that exception. When this method is invoked, it attemps to
/// the HRESULT, and throws that exception. When this method is invoked, it attempts to
/// retrieve extra information regarding the error by using the unmanaged GetErrorInfo
/// function.
/// </exception>
@ -813,7 +813,7 @@ namespace System.Management.Automation
/// to a defined exception. If the HRESULT maps to a defined exception, ThrowExceptionForHR
/// creates an instance of the exception and throws it. Otherwise, it creates an instance
/// of System.Runtime.InteropServices.COMException, initializes the error code field with
/// the HRESULT, and throws that exception. When this method is invoked, it attemps to
/// the HRESULT, and throws that exception. When this method is invoked, it attempts to
/// retrieve extra information regarding the error by using the unmanaged GetErrorInfo
/// function.
/// </exception>
@ -932,7 +932,7 @@ namespace System.Management.Automation
}
finally
{
// FailFast if something went wrong and SubmitReport didn't terminate the proces
// FailFast if something went wrong and SubmitReport didn't terminate the process
// (or simply if not registered)
Environment.FailFast((null != exception) ? exception.Message : string.Empty);
}

View file

@ -6,7 +6,7 @@ Copyright (c) Microsoft Corporation. All rights reserved.
// defined here to call Diagnostics.Assert when only ASSERTIONS_TRACE is defined
// Any #if DEBUG is pointless (always true) in this file because of this declaration.
// The presence of the define will cause the System.Diagnostics.Debug.Asser calls
// allways to be compiled in for this file. What can be compiled out are the calls to
// always to be compiled in for this file. What can be compiled out are the calls to
// System.Management.Automation.Diagnostics.Assert in other files when neither DEBUG
// nor ASSERTIONS_TRACE is defined.
#define DEBUG
@ -115,7 +115,7 @@ namespace System.Management.Automation
/// Basic assertion with logical condition and message
/// </summary>
/// <param name="condition">
/// logical condtion that should be true for program to proceed
/// logical condition that should be true for program to proceed
/// </param>
/// <param name="whyThisShouldNeverHappen">
/// Message to explain why condition should always be true
@ -144,7 +144,7 @@ namespace System.Management.Automation
/// Basic assertion with logical condition, message and detailed message
/// </summary>
/// <param name="condition">
/// logical condtion that should be true for program to proceed
/// logical condition that should be true for program to proceed
/// </param>
/// <param name="whyThisShouldNeverHappen">
/// Message to explain why condition should always be true

View file

@ -131,7 +131,7 @@ namespace System.Management.Automation.PerformanceData
/// <summary>
/// If isNumerator is true, then updates the numerator component
/// of target counter 'counterName' by a value given by 'stepAmount'.
/// Otherwise, updaqtes the denominator component by 'stepAmount'.
/// Otherwise, updates the denominator component by 'stepAmount'.
/// </summary>
public abstract bool UpdateCounterByValue(
string counterName,
@ -328,7 +328,7 @@ namespace System.Management.Automation.PerformanceData
{
this.Dispose(true);
// This object will be cleaned up by the Dispose method.
// Therefore, you should call GC.SupressFinalize to
// Therefore, you should call GC.SuppressFinalize to
// take this object off the finalization queue
// and prevent finalization code for this object
// from executing a second time.

View file

@ -8,7 +8,7 @@ using System.Diagnostics.CodeAnalysis;
namespace System.Management.Automation.PerformanceData
{
/// <summary>
/// A struct that encapuslates the information pertaining to a given counter
/// A struct that encapsulates the information pertaining to a given counter
/// like name,type and id.
/// </summary>
[System.Diagnostics.CodeAnalysis.SuppressMessage("Microsoft.Performance", "CA1815:OverrideEqualsAndOperatorEqualsOnValueTypes")]

View file

@ -14,7 +14,7 @@ namespace System.Management.Automation.PerformanceData
/// <summary>
/// Powershell Performance Counters Manager class shall provide a mechanism
/// for components using SYstem.Management.Automation assembly to register
/// performance counters with Performance Counters susbsystem.
/// performance counters with Performance Counters subsystem.
/// </summary>
[System.Diagnostics.CodeAnalysis.SuppressMessage("Microsoft.Naming", "CA1704:IdentifiersShouldBeSpelledCorrectly")]
public class PSPerfCountersMgr
@ -37,7 +37,7 @@ namespace System.Management.Automation.PerformanceData
#endregion
#region Desctructor
#region Destructor
/// <summary>
/// Destructor which will trigger the cleanup of internal data structures and

View file

@ -64,7 +64,7 @@ namespace System.Management.Automation.Tracing
private set;
}
/// <summary> Gets whether the event is sucessfully written </summary>
/// <summary> Gets whether the event is successfully written </summary>
public bool Success
{
get;
@ -83,7 +83,7 @@ namespace System.Management.Automation.Tracing
/// Creates a new instance of EtwEventArgs class.
/// </summary>
/// <param name="descriptor">Event descriptor</param>
/// <param name="success">Indicate whether the event is sucessfully written</param>
/// <param name="success">Indicate whether the event is successfully written</param>
/// <param name="payload">Event payload</param>
public EtwEventArgs(EventDescriptor descriptor, bool success, object[] payload)
{
@ -110,7 +110,7 @@ namespace System.Management.Automation.Tracing
private AsyncCallback asyncCallback;
/// <summary>
/// parantActivityId
/// parentActivityId
/// </summary>
protected readonly Guid parentActivityId;
private readonly EtwActivity tracer;

View file

@ -33,7 +33,7 @@ namespace System.Management.Automation.Tracing
#endregion
#region Instsance Access
#region Instance Access
public Delegate Invoker
{