Example #1
0
        public override object GetDefaultValue(SysDefaultConstraint columnConstraint)
        {
            var hexString = TrimStart(columnConstraint.Definition.Trim('(', ')').TrimStart(), "0x");

            try
            {
                return(StringToByteArray(hexString));
            }
            catch
            {
                return(null);
            }
        }
Example #2
0
 public override object GetDefaultValue(SysDefaultConstraint columnConstraint)
 {
     return(short.TryParse(columnConstraint.Definition.Trim('(', ')'), out var parsedResult) ? parsedResult : (object)null);
 }
Example #3
0
        public override object GetDefaultValue(SysDefaultConstraint columnConstraint)
        {
            var bracketLessString = columnConstraint.Definition.Trim('(', ')');

            return(bracketLessString == "0" ? false : (bracketLessString == "1" ? true : (object)null));
        }
Example #4
0
        public override object GetDefaultValue(SysDefaultConstraint columnConstraint)
        {
            var bracketLessString = columnConstraint.Definition.Trim('(', ')');

            return(bracketLessString.StartsWith("'") ? bracketLessString.Trim('\'') : null);
        }
Example #5
0
 public override object GetDefaultValue(SysDefaultConstraint columnConstraint)
 {
     return(null);
 }
Example #6
0
 public abstract object GetDefaultValue(SysDefaultConstraint columnConstraint);