コード例 #1
0
        protected virtual PropertyBuilder <TMember> Map <TMember>(Member property, string columnName)
        {
            var mapping         = new PropertyMapping();
            var propertyBuilder = new PropertyBuilder <TMember>(mapping, typeof(T), property);

            if (!string.IsNullOrEmpty(columnName))
            {
                propertyBuilder.Name(columnName);
            }
            else
            {
                propertyBuilder.Name(property.Name);
            }
            _mappings.Add(mapping);
            return(propertyBuilder);
        }
コード例 #2
0
 protected override void Context()
 {
     var map = LuceneMapper.GetMappingForType(typeof(TestObject));
     _mapping = map.Mappings.First(x => x.Name == "ValidProperty");
 }