예제 #1
0
        public static string GetProperty(this DatabaseColumn column)
        {
            var dataType = column.GetDataType();

            return(new StringBuilder(Templates.PropertyTemplate)
                   .Replace("$dataType$", dataType)
                   .Replace("$name$", column.Name)
                   .ToString());
        }
예제 #2
0
        public static string GetField(this DatabaseColumn column)
        {
            var dataType = column.GetDataType();

            return(new StringBuilder(Templates.FieldTemplate)
                   .Replace("$dataType$", dataType)
                   .Replace("$name$", (column.Name.First() + "").ToLower() + column.Name.Substring(1, column.Name.Length - 1))
                   .ToString());
        }