Refactoring database creation, adding sql syntax provider to account for differences in syntax between sql, ce and mysql.

Adding MySql unit test.
This commit is contained in:
sitereactor
2012-10-19 13:20:57 -02:00
parent e34298c9f3
commit c1909eccf5
47 changed files with 844 additions and 384 deletions

View File

@@ -0,0 +1,23 @@
using System;
namespace Umbraco.Core.Persistence.SqlSyntax
{
internal static class SyntaxConfig
{
private static ISqlSyntaxProvider _sqlSyntaxProvider;
public static ISqlSyntaxProvider SqlSyntaxProvider
{
get
{
if(_sqlSyntaxProvider == null)
{
throw new ArgumentNullException("SqlSyntaxProvider",
"You must set the singleton 'Umbraco.Core.Persistence.SqlSyntax.SyntaxConfig' to use an sql syntax provider");
}
return _sqlSyntaxProvider;
}
set { _sqlSyntaxProvider = value; }
}
}
}