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

This commit is contained in:
Josh Soref 2016-08-28 05:48:06 +00:00
parent c59e992c25
commit 92a121a655
27 changed files with 64 additions and 64 deletions

View file

@ -126,14 +126,14 @@ namespace System.Management.Automation
/// <remarks>
/// This will,
/// a. use _sessionState object to get a list of alias that match the target.
/// b. for each alias, retrive help info as in ExactMatchHelp.
/// b. for each alias, retrieve help info as in ExactMatchHelp.
/// </remarks>
/// <param name="helpRequest">help request object</param>
/// <param name="searchOnlyContent">
/// If true, searches for pattern in the help content. Individual
/// provider can decide which content to search in.
///
/// If false, seraches for pattern in the command names.
/// If false, searches for pattern in the command names.
/// </param>
/// <returns>a IEnumerable of helpinfo object</returns>
internal override IEnumerable<HelpInfo> SearchHelp(HelpRequest helpRequest, bool searchOnlyContent)

View file

@ -371,7 +371,7 @@ namespace System.Management.Automation
}
/// <summary>
/// Returs help information for a parameter(s) identified by pattern
/// Returns help information for a parameter(s) identified by pattern
/// </summary>
/// <param name="pattern">pattern to search for parameters</param>
/// <returns>A collection of parameters that match pattern</returns>

View file

@ -22,7 +22,7 @@ namespace System.Management.Automation.Internal
#region IDisposable Interface
//
// This is a special case of the IDisposable pattern becaue the resource
// This is a special case of the IDisposable pattern because the resource
// to be disposed is managed by the derived class. The implementation here
// enables derived classes to handle it cleanly.
//

View file

@ -196,7 +196,7 @@ namespace System.Management.Automation.Internal
internal static class CabinetNativeApi
{
#region Delegates and function defintions
#region Delegates and function definitions
[UnmanagedFunctionPointer(CallingConvention.Cdecl, CharSet = CharSet.Ansi)]
internal delegate IntPtr FdiAllocDelegate(int size);
@ -617,7 +617,7 @@ namespace System.Management.Automation.Internal
#endregion
#region PInvoke Defintions
#region PInvoke Definitions
/// <summary>
/// Creates an FDI context

View file

@ -261,7 +261,7 @@ namespace System.Management.Automation
if (sb != null)
{
helpFile = null;
// serachOnlyContent == true means get-help is looking into the content, in this case we dont
// searchOnlyContent == true means get-help is looking into the content, in this case we dont
// want to download the content from the remote machine. Reason: In Exchange scenario there
// are ~700 proxy commands, downloading help for all the commands and searching in that
// content takes a lot of time (in the order of 30 minutes) for their scenarios.
@ -401,8 +401,8 @@ namespace System.Management.Automation
/// </summary>
///
/// <remarks>
/// ExactMatchHelp is overrided instead of DoExactMatchHelp to make sure
/// all help item retrival will go through command discovery. Because each
/// ExactMatchHelp is overridden instead of DoExactMatchHelp to make sure
/// all help item retrieval will go through command discovery. Because each
/// help file can contain multiple help items for different commands. Directly
/// retrieve help cache can result in a invalid command to contain valid
/// help item. Forcing each ExactMatchHelp to go through command discovery
@ -591,7 +591,7 @@ namespace System.Management.Automation
if (String.IsNullOrEmpty(location))
{
// If the help file could not be found, then it is possible that the actual assembly name is something like
// <Name>.ni.dll, e.g., MyAsembly.ni.dll, so lets try to find the original help file in the cmdlet metadata.
// <Name>.ni.dll, e.g., MyAssembly.ni.dll, so lets try to find the original help file in the cmdlet metadata.
location = GetHelpFile(helpFile, cmdletInfo);
}
}
@ -794,14 +794,14 @@ namespace System.Management.Automation
HelpInfo result = GetFromCommandCache(helpFileIdentifier, commandInfo.Name, commandInfo.HelpCategory);
if (null == result)
{
// check if the command is prefixed and try retreiving help by removing the prefix
// check if the command is prefixed and try retrieving help by removing the prefix
if ((commandInfo.Module != null) && (!string.IsNullOrEmpty(commandInfo.Prefix)))
{
MamlCommandHelpInfo newMamlHelpInfo = GetFromCommandCacheByRemovingPrefix(helpFileIdentifier, commandInfo);
if (null != newMamlHelpInfo)
{
// caching the changed help content under the prefixed name for faster
// retreival later.
// retrieval later.
AddToCommandCache(helpFileIdentifier, commandInfo.Name, newMamlHelpInfo);
return newMamlHelpInfo;
}
@ -824,7 +824,7 @@ namespace System.Management.Automation
HelpInfo result = GetFromCommandCache(cmdletInfo.ModuleName, cmdletInfo.Name, cmdletInfo.HelpCategory);
if (result == null)
{
// check if the command is prefixed and try retreiving help by removing the prefix
// check if the command is prefixed and try retrieving help by removing the prefix
if ((cmdletInfo.Module != null) && (!string.IsNullOrEmpty(cmdletInfo.Prefix)))
{
MamlCommandHelpInfo newMamlHelpInfo = GetFromCommandCacheByRemovingPrefix(cmdletInfo.ModuleName, cmdletInfo);
@ -845,7 +845,7 @@ namespace System.Management.Automation
}
// caching the changed help content under the prefixed name for faster
// retreival later.
// retrieval later.
AddToCommandCache(cmdletInfo.ModuleName, cmdletInfo.Name, newMamlHelpInfo);
return newMamlHelpInfo;
}
@ -862,7 +862,7 @@ namespace System.Management.Automation
/// original command name (without prefix) as the key.
///
/// This method retrieves the help content by suppressing the prefix and then making a copy
/// of the help contnet + change the name and then returns the copied help content.
/// of the help content + change the name and then returns the copied help content.
/// </summary>
/// <param name="helpIdentifier"></param>
/// <param name="cmdInfo"></param>
@ -882,7 +882,7 @@ namespace System.Management.Automation
if (null != originalHelpInfo)
{
result = originalHelpInfo.Copy();
// command's name can be changed using -Prefix while importing module.To give better user expereience for
// command's name can be changed using -Prefix while importing module.To give better user experience for
// get-help (on par with get-command), it was decided to use the prefixed command name
// for the help content.
if (result.FullHelp.Properties["Name"] != null)
@ -982,7 +982,7 @@ namespace System.Management.Automation
/// <param name="helpRequest">help request object</param>
/// <param name="searchOnlyContent">
/// If true, searches for pattern in the help content of all cmdlets.
/// Otherwise, seraches for pattern in the cmdlet names.
/// Otherwise, searches for pattern in the cmdlet names.
/// </param>
/// <returns></returns>
internal override IEnumerable<HelpInfo> SearchHelp(HelpRequest helpRequest, bool searchOnlyContent)

View file

@ -235,7 +235,7 @@ namespace System.Management.Automation.Help
Collection<CommandParameterInfo> parameters = new Collection<CommandParameterInfo>();
// GenerateParameters parameters in display order
// ie., Postional followed by
// ie., Positional followed by
// Named Mandatory (in alpha numeric) followed by
// Named (in alpha numeric)
parameterSet.GenerateParametersInDisplayOrder(commonWorkflow,
@ -256,7 +256,7 @@ namespace System.Management.Automation.Help
/// <param name="obj">HelpInfo object</param>
/// <param name="parameters">
/// a collection of parameters in display order
/// ie., Postional followed by
/// ie., Positional followed by
/// Named Mandatory (in alpha numeric) followed by
/// Named (in alpha numeric)
/// </param>

View file

@ -201,7 +201,7 @@ namespace Microsoft.PowerShell.Commands
private bool _showWindow;
/// <summary>
/// Gets and sets a value indicatuing whether the help should be displayed in a separate window
/// Gets and sets a value indicating whether the help should be displayed in a separate window
/// </summary>
[Parameter(ParameterSetName = "ShowWindow", Mandatory = true)]
public SwitchParameter ShowWindow
@ -397,7 +397,7 @@ namespace Microsoft.PowerShell.Commands
/// Change <paramref name="originalHelpObject"/> as per user request.
///
/// This method creates a new type to the existing typenames
/// depending on Detailed,Full,Example parameteres and adds this
/// depending on Detailed,Full,Example parameters and adds this
/// new type(s) to the top of the list.
/// </summary>
/// <param name="originalHelpObject">Full help object to transform.</param>
@ -456,7 +456,7 @@ namespace Microsoft.PowerShell.Commands
}
/// <summary>
/// Gets the paramater info for patterns identified Parameter property.
/// Gets the parameter info for patterns identified Parameter property.
/// Writes the parameter info(s) to the output stream. An error is thrown
/// if a parameter with a given pattern is not found.
/// </summary>

View file

@ -1140,7 +1140,7 @@ namespace System.Management.Automation
}
// comment block is behind function definition
// we don't suport it for configuration delaration as this style is rarely used
// we don't support it for configuration declaration as this style is rarely used
if (funcDefnAst != null)
{
startTokenIndex =

View file

@ -44,10 +44,10 @@ namespace System.Management.Automation
/// TraceFrame instance exists in a scope governed by using statement. It is possible
/// that a new TraceFrame instance will be created in the scope of another TraceFrame
/// instance. The scopes of various live TraceFrame instances form a stack which is
/// similiar to call stacks of normal C# functions. This is why we call this class
/// similar to call stacks of normal C# functions. This is why we call this class
/// a "TraceFrame"
///
/// TraceFrame itself implements IDisposable interface to guarrentee a chance to
/// TraceFrame itself implements IDisposable interface to guarantee a chance to
/// write errors into system error pool when execution gets out of its scope. During
/// disposal time, errorRecords accumulated will be written to system error pool
/// together with error context information collected at instance creation.

View file

@ -18,7 +18,7 @@ namespace System.Management.Automation
/// Constructor for HelpFileHelpInfo
/// </summary>
/// <remarks>
/// This is made private intentally so that the only way to create object of this type
/// This is made private intentionally so that the only way to create object of this type
/// is through
/// GetHelpInfo(string name, string text, string filename)
/// </remarks>

View file

@ -100,7 +100,7 @@ namespace System.Management.Automation
/// <summary>
/// Target object in forward-help-provider that should process this HelpInfo.
/// This will serve as auxilliary information to be passed to forward help provider.
/// This will serve as auxiliary information to be passed to forward help provider.
///
/// In the case of AliasHelpInfo, for example, it needs to be forwarded to
/// CommandHelpProvider to fill in detailed helpInfo. In that case, ForwardHelpCategory
@ -140,7 +140,7 @@ namespace System.Management.Automation
}
/// <summary>
/// Returs help information for a parameter(s) identified by pattern
/// Returns help information for a parameter(s) identified by pattern
/// </summary>
/// <param name="pattern">pattern to search for parameters</param>
/// <returns>A collection of parameters that match pattern</returns>

View file

@ -143,7 +143,7 @@ namespace System.Management.Automation
/// Retrieve help info that exactly match the target.
/// </summary>
/// <param name="helpRequest">help request object</param>
/// <returns>List of HelpInfo objects retrived</returns>
/// <returns>List of HelpInfo objects retrieved</returns>
internal abstract IEnumerable<HelpInfo> ExactMatchHelp(HelpRequest helpRequest);
/// <summary>
@ -154,7 +154,7 @@ namespace System.Management.Automation
/// If true, searches for pattern in the help content. Individual
/// provider can decide which content to search in.
///
/// If false, seraches for pattern in the command names.
/// If false, searches for pattern in the command names.
/// </param>
/// <returns>a collection of help info objects</returns>
internal abstract IEnumerable<HelpInfo> SearchHelp(HelpRequest helpRequest, bool searchOnlyContent);

View file

@ -93,8 +93,8 @@ namespace System.Management.Automation
/// </summary>
/// <remarks>
/// Derived class can choose to either override ExactMatchHelp method to DoExactMatchHelp method.
/// If ExactMatchHelp is overriden, initial cache checking will be disabled by default.
/// If DoExactMatchHelp is overriden, cache check will be done first in ExactMatchHelp before the
/// If ExactMatchHelp is overridden, initial cache checking will be disabled by default.
/// If DoExactMatchHelp is overridden, cache check will be done first in ExactMatchHelp before the
/// logic in DoExactMatchHelp is in place.
/// </remarks>
/// <param name="helpRequest">help request object</param>
@ -110,7 +110,7 @@ namespace System.Management.Automation
/// If true, searches for pattern in the help content. Individual
/// provider can decide which content to search in.
///
/// If false, seraches for pattern in the command names.
/// If false, searches for pattern in the command names.
/// </param>
/// <returns>a collection of help info objects</returns>
internal override IEnumerable<HelpInfo> SearchHelp(HelpRequest helpRequest, bool searchOnlyContent)

View file

@ -64,7 +64,7 @@ namespace System.Management.Automation
/// If true, searches for pattern in the help content. Individual
/// provider can decide which content to search in.
///
/// If false, seraches for pattern in the command names.
/// If false, searches for pattern in the command names.
/// </param>
/// <returns>a collection of help info objects</returns>
internal sealed override IEnumerable<HelpInfo> SearchHelp(HelpRequest helpRequest, bool searchOnlyContent)

View file

@ -17,7 +17,7 @@ namespace System.Management.Automation
/// <summary>
/// Monad help is an architecture made up of three layers:
/// 1. At the top is get-help commandlet from where help functionality is accessed.
/// 2. At the middel is the help system which collects help objects based on user's request.
/// 2. At the middle is the help system which collects help objects based on user's request.
/// 3. At the bottom are different help providers which provide help contents for different kinds of information requested.
///
/// Class HelpSystem implements the middle layer of Monad Help.
@ -48,7 +48,7 @@ namespace System.Management.Automation
/// Help Api:
/// Help Api is the function to be called by get-help commandlet.
///
/// Following information needs to be provided in Help Api paramters,
/// Following information needs to be provided in Help Api parameters,
/// 1. search target: (which can be one or multiple strings)
/// 2. help type: limit the type of help to be searched.
/// 3. included fields: the fields to be included in the help info
@ -145,7 +145,7 @@ namespace System.Management.Automation
InitializeHelpProviders();
}
#endregion Initalization
#endregion Initialization
#region Help API
@ -290,7 +290,7 @@ namespace System.Management.Automation
/// <summary>
/// Get help based on the target, help type, etc
///
/// Help eninge retrieve help based on following schemes,
/// Help engine retrieve help based on following schemes,
///
/// 1. if help target is empty, get default help
/// 2. if help target is not a search pattern, try to retrieve exact help
@ -411,7 +411,7 @@ namespace System.Management.Automation
/// <param name="helpInfo"></param>
/// <param name="helpRequest">Help request object</param>
/// <returns>Never returns null.</returns>
/// <remarks>helpInfos is not null or emtpy.</remarks>
/// <remarks>helpInfos is not null or empty.</remarks>
private IEnumerable<HelpInfo> ForwardHelp(HelpInfo helpInfo, HelpRequest helpRequest)
{
Collection<HelpInfo> result = new Collection<HelpInfo>();

View file

@ -43,7 +43,7 @@ namespace System.Management.Automation
/// 1. a file name
/// 2. a search pattern
/// It can also include a path, in that case,
/// 1. the path will be searched first for the existense of the files.
/// 1. the path will be searched first for the existence of the files.
/// </summary>
internal string Target { get; } = null;

View file

@ -163,7 +163,7 @@ namespace System.Management.Automation
// particular component, role and functionality using parameters like
// -component, -role, -functionality.
// 3. At runtime, help engine will match against component/role/functionality
// criteria before returing help results.
// criteria before returning help results.
//
private string _component = null;
@ -276,7 +276,7 @@ namespace System.Management.Automation
/// <summary>
/// Merge the provider specific help with current command help.
///
/// The cmdletHelp and dynamicParameterHelp is normally retrived from ProviderHelpProvider.
/// The cmdletHelp and dynamicParameterHelp is normally retrieved from ProviderHelpProvider.
/// </summary>
/// <remarks>
/// A new MamlCommandHelpInfo is created to avoid polluting the provider help cache.
@ -292,7 +292,7 @@ namespace System.Management.Automation
MamlCommandHelpInfo result = (MamlCommandHelpInfo)this.MemberwiseClone();
// We will need to use a deep clone of _fullHelpObject
// to avoid _fullHelpObject being get tarminated.
// to avoid _fullHelpObject being get terminated.
result._fullHelpObject = this._fullHelpObject.Copy();
if (cmdletHelp != null)
@ -333,7 +333,7 @@ namespace System.Management.Automation
/// <summary>
/// Given a PSObject, this method will traverse through the objects properties,
/// extracts content from properities that are of type System.String, appends them
/// extracts content from properties that are of type System.String, appends them
/// together and returns.
/// </summary>
/// <param name="psObject"></param>

View file

@ -17,7 +17,7 @@ namespace System.Management.Automation
/// etc, which needs to be taken care of during display. As a result, xml node in Maml schema can't be
/// converted into PSObject directly with XmlNodeAdapter.
///
/// MamlNode class provides logic in converting formatting tags into the format accetable by monad format
/// MamlNode class provides logic in converting formatting tags into the format acceptable by monad format
/// and output engine.
///
/// Following three kinds of formating tags are supported per our agreement with Maml team,
@ -61,10 +61,10 @@ namespace System.Management.Automation
/// <tag>*</tag>
/// <text>text for list item 2</text>
/// </textItem>
/// 3. definitionList => a list of defintionTextItem's
/// 3. definitionList => a list of definitionTextItem's
/// <definitionListItem>
/// <term>definition term here</term>
/// <definition>defintion text here</definition>
/// <definition>definition text here</definition>
/// </definitionListItem>
/// </summary>
///
@ -380,7 +380,7 @@ namespace System.Management.Automation
/// "attrib1" will be lost. This seems to be OK with current practice of authoring
/// monad command help.
/// </summary>
/// <param name="properties">property hastable</param>
/// <param name="properties">property hashtable</param>
/// <param name="name">property name</param>
/// <param name="mshObject">property value</param>
private static void AddProperty(Hashtable properties, string name, PSObject mshObject)
@ -805,7 +805,7 @@ namespace System.Management.Automation
/// two properties,
/// a. tag=" 1. " or " 2. "
/// b. text="text for list item 1" or "text for list item 2"
/// In the case of unordered list, similiar PSObject will created with type to be "MamlUnorderedListText" and tag="*"
/// In the case of unordered list, similar PSObject will created with type to be "MamlUnorderedListText" and tag="*"
///
/// </summary>
/// <param name="xmlNode"></param>
@ -977,16 +977,16 @@ namespace System.Management.Automation
/// Convert an definitionListItem node into an PSObject
///
/// For example
/// <defintionListItem>
/// <definitionListItem>
/// <term>
/// term text
/// </term>
/// <definition>
/// <para>
/// definiton text
/// definition text
/// </para>
/// </definition>
/// </defintionListItem>
/// </definitionListItem>
/// In this case, an PSObject of type "definitionListText" will be created with following
/// properties
/// a. term="term text"
@ -1185,7 +1185,7 @@ namespace System.Management.Automation
}
/// <summary>
/// Get mininum indentation of a paragraph
/// Get minimum indentation of a paragraph
/// </summary>
/// <param name="lines"></param>
/// <returns></returns>
@ -1208,7 +1208,7 @@ namespace System.Management.Automation
}
/// <summary>
/// Get indetation of a line, i.e., number of spaces
/// Get indentation of a line, i.e., number of spaces
/// at the beginning of the line.
/// </summary>
/// <param name="line"></param>

View file

@ -188,7 +188,7 @@ namespace System.Management.Automation
}
/// <summary>
/// Get propery info.
/// Get property info.
/// </summary>
internal static PSPropertyInfo GetProperyInfo(PSObject psObject, string[] path)
{

View file

@ -126,7 +126,7 @@ namespace System.Management.Automation
/// <summary>
/// Get the help in for the PS Class Info. ///
/// </summary>
/// <param name="searcher">Searcher for PS Classses.</param>
/// <param name="searcher">Searcher for PS Classes.</param>
/// <returns>Next HelpInfo object.</returns>
private IEnumerable<HelpInfo> GetHelpInfo(PSClassSearcher searcher)
{

View file

@ -112,7 +112,7 @@ namespace System.Management.Automation
throw new ItemNotFoundException(_requestedPath, "PathNotFound", SessionStateStrings.PathNotFound);
}
// ok we have path and valid provider that supplys content..intialize the provider
// ok we have path and valid provider that supplys content..initialize the provider
// and get the help content for the path.
cmdletProvider.Start(providerInfo, cmdletProviderContext);
// There should be exactly one resolved path.

View file

@ -263,7 +263,7 @@ namespace System.Management.Automation
private Hashtable _dynamicParameterHelps;
/// <summary>
/// Return the provider-specific dynamic paramter help based on input parameter name
/// Return the provider-specific dynamic parameter help based on input parameter name
/// </summary>
/// <param name="parameters">an array of parameters to retrieve help</param>
/// <returns>an array of mshObject that contains the parameter help</returns>

View file

@ -264,7 +264,7 @@ namespace System.Management.Automation
/// If true, searches for pattern in the help content. Individual
/// provider can decide which content to search in.
///
/// If false, seraches for pattern in the command names.
/// If false, searches for pattern in the command names.
/// </param>
/// <returns></returns>
internal override IEnumerable<HelpInfo> SearchHelp(HelpRequest helpRequest, bool searchOnlyContent)

View file

@ -52,7 +52,7 @@ namespace System.Management.Automation
_deserializedRemoteHelp = helpResults[0];
_deserializedRemoteHelp.Methods.Remove("ToString");
// Win8: bug9457: Remote proxy command's name can be changed locally using -Prefix
// parameter of the Import-PSSession cmdlet. To give better user expereience for
// parameter of the Import-PSSession cmdlet. To give better user experience for
// get-help (on par with get-command), it was decided to use the local command name
// for the help content.
PSPropertyInfo nameInfo = _deserializedRemoteHelp.Properties["Name"];

View file

@ -16,7 +16,7 @@ using System.Diagnostics;
namespace Microsoft.PowerShell.Commands
{
/// <summary>
/// This class implements the Save-Help cmdleto
/// This class implements the Save-Help cmdlet
/// </summary>
[Cmdlet(VerbsData.Save, "Help", DefaultParameterSetName = SaveHelpCommand.PathParameterSetName,
HelpUri = "http://go.microsoft.com/fwlink/?LinkID=210612")]

View file

@ -799,7 +799,7 @@ namespace Microsoft.PowerShell.Commands
#region Logging
/// <summary>
/// Loggs a command message
/// Logs a command message
/// </summary>
/// <param name="message">message to log</param>
internal void LogMessage(string message)

View file

@ -869,7 +869,7 @@ namespace System.Management.Automation.Help
}
/// <summary>
/// Downloads the help cotent
/// Downloads the help content
/// </summary>
/// <param name="commandType">command type</param>
/// <param name="path">destination path</param>
@ -1267,7 +1267,7 @@ namespace System.Management.Automation.Help
string cabDir = Path.GetDirectoryName(srcPath);
// Cabinet API doens't handle the trailing back slash
// Cabinet API doesn't handle the trailing back slash
if (!cabDir.EndsWith("\\", StringComparison.Ordinal))
{
cabDir += "\\";