private IEnumerable<SQLiteConnection.ColumnInfo> GetExpectedColumnInfos(IReflectionService reflectionService, Type type) { var expectedValues = from prop in reflectionService.GetPublicInstanceProperties(type) select new SQLiteConnection.ColumnInfo { Name = prop.Name, notnull = ((!prop.GetCustomAttributes<NotNullAttribute>(true).Any()) && (!prop.GetCustomAttributes<PrimaryKeyAttribute>(true).Any())) ? 0 : 1 }; return expectedValues; }
private IEnumerable <SQLiteConnection.ColumnInfo> GetExpectedColumnInfos(IReflectionService reflectionService, Type type) { var expectedValues = from prop in reflectionService.GetPublicInstanceProperties(type) select new SQLiteConnection.ColumnInfo { Name = prop.Name, notnull = ((!prop.GetCustomAttributes <NotNullAttribute>(true).Any()) && (!prop.GetCustomAttributes <PrimaryKeyAttribute>(true).Any())) ? 0 : 1 }; return(expectedValues); }
// // Constructor public TableMappingBridge(TableMapping tableMapping, IReflectionService reflectionService) { TableMapping = tableMapping; Properties = reflectionService.GetPublicInstanceProperties(tableMapping.MappedType); }