public DocumentationEntry(string typeName, string propertyName, Type propertyType, string content) { this.typeName = typeName; this.propertyName = propertyName; this.propertyTypeName = TypeNameFormatter.FormatTypeForDefaultLanguage(propertyType, false); this.content = content; }
public static string FormatTypeName(Type type) { if (type == (Type)null) { return(string.Empty); } Type nullableType = PlatformTypeHelper.GetNullableType(type); string shortName = TypeNameFormatter.GetShortName(TypeNameFormatter.FormatTypeForDefaultLanguage(nullableType, true)); if (!(nullableType != (Type)null)) { return(shortName); } return(shortName + "?"); }