Example #1
0
        public static SchemaName Parse(string?name)
        {
            if (!name.HasText())
            {
                return(SchemaName.Default);
            }

            var tuple = ObjectName.SplitLast(name);

            return(new SchemaName(DatabaseName.Parse(tuple.prefix), (tuple.name)));
        }
Example #2
0
        public static DatabaseName?Parse(string?name)
        {
            if (!name.HasText())
            {
                return(null);
            }

            var tuple = ObjectName.SplitLast(name);

            return(new DatabaseName(ServerName.Parse(tuple.prefix), tuple.name));
        }
        public static SchemaName Parse(string name)
        {
            if (string.IsNullOrEmpty(name))
            {
                return(SchemaName.Default);
            }

            var tuple = ObjectName.SplitLast(name);

            return(new SchemaName(DatabaseName.Parse(tuple.prefix), (tuple.name)));
        }
Example #4
0
        public static SchemaName Parse(string?name, bool isPostgres)
        {
            if (!name.HasText())
            {
                return(SchemaName.Default(isPostgres));
            }

            var tuple = ObjectName.SplitLast(name, isPostgres);

            return(new SchemaName(DatabaseName.Parse(tuple.prefix, isPostgres), tuple.name, isPostgres));
        }
        public static DatabaseName Parse(string name)
        {
            if (string.IsNullOrEmpty(name))
            {
                return(null);
            }

            var tuple = ObjectName.SplitLast(name);

            return(new DatabaseName(ServerName.Parse(tuple.prefix), tuple.name));
        }