Exemplo n.º 1
0
        public void Apply(IPropertyInstance instance)
        {
            string columnName = ConventionUtils.CamelCaseToUnderscore(instance.Property.Name);

            if (instance.Type == typeof(string))
            {
                columnName = "N_" + columnName;
            }

            if (instance.Type == typeof(char))
            {
                columnName = "N_BL_" + columnName;
            }

            if (instance.Type == typeof(DateTime))
            {
                columnName = "FEC_" + columnName;
            }

            instance.Column(columnName);
            //instance.
        }
Exemplo n.º 2
0
        public void Apply(IIdentityInstance instance)
        {
            string primaryKeyName = ConventionUtils.CamelCaseToUnderscore(instance.EntityType.Name);

            instance.Column("ID_" + primaryKeyName);
        }
Exemplo n.º 3
0
        public void Apply(IManyToOneInstance instance)
        {
            string referenceName = ConventionUtils.CamelCaseToUnderscore(instance.Property.PropertyType.Name);

            instance.Column("ID_" + referenceName);
        }