public static Field BuildField(string name, object val, IAzureProviderIndex index) { var fld = index.AzureConfiguration.FieldMap.GetFieldConfiguration(name) as AzureSearchFieldConfiguration; if (fld != null) { return(BuildField(name, fld)); } var dataType = DataType.String; dataType = AzureDocumentBuilder.GetDataType(val); var searchable = dataType == DataType.String; //Build new Field var field = new Field() { IsFacetable = false, IsFilterable = false, IsKey = false, IsRetrievable = true, IsSearchable = searchable, IsSortable = true, Name = name, Type = dataType }; return(field); }
public IndexData(ISearchIndex index, IIndexable indexable, AzureDocumentBuilder documentBuilder) : this(index, indexable, documentBuilder.Document, documentBuilder.CollectedFields) { }