本文整理汇总了C#中StringBuilder.AddSpacesInFront方法的典型用法代码示例。如果您正苦于以下问题:C# StringBuilder.AddSpacesInFront方法的具体用法?C# StringBuilder.AddSpacesInFront怎么用?C# StringBuilder.AddSpacesInFront使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类StringBuilder
的用法示例。
在下文中一共展示了StringBuilder.AddSpacesInFront方法的1个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。
示例1: ToString
/// <summary>
/// A string representation of the ScaleCapacity including indentation
/// </summary>
/// <param name="ruleEventDataSource">The RuleManagementEventDataSource object</param>
/// <param name="indentationTabs">The number of tabs to insert in front of each member</param>
/// <returns>A string representation of the ScaleCapacity including indentation</returns>
public static string ToString(this RuleManagementEventDataSource ruleEventDataSource, int indentationTabs)
{
//RuleManagementEventDataSource
StringBuilder output = new StringBuilder();
if (ruleEventDataSource != null)
{
output.AppendLine();
output.AddSpacesInFront(indentationTabs).AppendLine("EventName : " + ruleEventDataSource.EventName);
output.AddSpacesInFront(indentationTabs).AppendLine("Category : " + ruleEventDataSource.EventSource);
output.AddSpacesInFront(indentationTabs).AppendLine("Level : " + ruleEventDataSource.Level);
output.AddSpacesInFront(indentationTabs).AppendLine("OperationName : " + ruleEventDataSource.OperationName);
output.AddSpacesInFront(indentationTabs).AppendLine("ResourceGroupName : " + ruleEventDataSource.ResourceGroupName);
output.AddSpacesInFront(indentationTabs).AppendLine("ResourceProviderName : " + ruleEventDataSource.ResourceProviderName);
output.AddSpacesInFront(indentationTabs).AppendLine("ResourceId : " + ruleEventDataSource.ResourceUri);
output.AddSpacesInFront(indentationTabs).AppendLine("Status : " + ruleEventDataSource.Status);
output.AddSpacesInFront(indentationTabs).AppendLine("SubStatus : " + ruleEventDataSource.SubStatus);
output.AddSpacesInFront(indentationTabs).Append("Claims : " + ruleEventDataSource.Claims);
}
return output.ToString();
}