Skip to content

Commit ed6ac5b

Browse files
Bring back a class gone unused for avoiding a binary breaking change
1 parent bfa41be commit ed6ac5b

File tree

1 file changed

+15
-0
lines changed

1 file changed

+15
-0
lines changed

src/NHibernate/Dialect/SQLiteDialect.cs

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
using System;
12
using System.Collections.Generic;
23
using System.Data;
34
using System.Data.Common;
@@ -498,5 +499,19 @@ public override bool SupportsForeignKeyConstraintInAlterTable
498499
// Said to be unlimited. http://sqlite.1065341.n5.nabble.com/Max-limits-on-the-following-td37859.html
499500
/// <inheritdoc />
500501
public override int MaxAliasLength => 128;
502+
503+
// Since v5.3
504+
[Obsolete("This class has no usage in NHibernate anymore and will be removed in a future version. Use or extend CastFunction instead.")]
505+
[Serializable]
506+
protected class SQLiteCastFunction : CastFunction
507+
{
508+
protected override bool CastingIsRequired(string sqlType)
509+
{
510+
if (StringHelper.ContainsCaseInsensitive(sqlType, "date") ||
511+
StringHelper.ContainsCaseInsensitive(sqlType, "time"))
512+
return false;
513+
return true;
514+
}
515+
}
501516
}
502517
}

0 commit comments

Comments
 (0)