public override string ToString()
{
List<KeyValuePair<string, object>> attributes = new List<KeyValuePair<string, object>>();
this.SaveAllProperties(attributes);
attributes.Sort((firstAttribute, secondAttribute) => firstAttribute.Key.CompareTo(secondAttribute.Key));
StringBuilder result = new StringBuilder();
result.Append(this.GetType().Name);
result.Append('[');
foreach (KeyValuePair<string, object> attribute in attributes)
{
var currentAttributeValue = attribute.Value;
if (currentAttributeValue != null)
{
result.Append(attribute.Key);
result.Append('=');
result.Append(currentAttributeValue);
result.Append(';');
}
}
result.Length--;
result.Append(']');
return result.ToString();
}
}