Esempio n. 1
0
 private static string NameOfField(SimpleFieldDescription field)
 {
     if (field.IsBackingField)
     {
         return(field.AsPropertyName());
     }
     return(field.Name);
 }
Esempio n. 2
0
        internal static IEnumerable <SimpleFieldDescription> CreateArrayField(ITypeDescription type)
        {
            var arrayType = ArrayDescription.Create(type, 1);

            return(new[] { SimpleFieldDescription.Create(FieldName, arrayType) });
        }
Esempio n. 3
0
 private static ExplorerItem ToExplorerItem(SimpleFieldDescription field)
 {
     return(new ExplorerItem(NameOfField(field) + ":" + field.Type.Name,
                             ExplorerItemKind.Property, ExplorerIcon.Column));
 }
Esempio n. 4
0
 internal static IEnumerable <SimpleFieldDescription> CreateField(string fieldName,
                                                                  ITypeDescription type)
 {
     return(new[] { SimpleFieldDescription.Create(fieldName, type) });
 }