private static string NameOfField(SimpleFieldDescription field) { if (field.IsBackingField) { return(field.AsPropertyName()); } return(field.Name); }
internal static IEnumerable <SimpleFieldDescription> CreateArrayField(ITypeDescription type) { var arrayType = ArrayDescription.Create(type, 1); return(new[] { SimpleFieldDescription.Create(FieldName, arrayType) }); }
private static ExplorerItem ToExplorerItem(SimpleFieldDescription field) { return(new ExplorerItem(NameOfField(field) + ":" + field.Type.Name, ExplorerItemKind.Property, ExplorerIcon.Column)); }
internal static IEnumerable <SimpleFieldDescription> CreateField(string fieldName, ITypeDescription type) { return(new[] { SimpleFieldDescription.Create(fieldName, type) }); }