/// <summary>
 /// Initializes a new instance of the <see cref="EmbeddedScriptProvider"/> class.
 /// </summary>
 /// <param name="assembly">The assembly.</param>
 /// <param name="filter">The embedded script filter.</param>
 /// <param name="codeScriptFilter">The embedded script filter. If null, filter is used.</param>
 /// <param name="sqlScriptOptions">The sql script options.</param>
 public EmbeddedScriptAndCodeProvider(Assembly assembly, Func <string, bool> filter, Func <string, bool> codeScriptFilter, SqlScriptOptions sqlScriptOptions)
 {
     this.assembly          = assembly;
     this.filter            = codeScriptFilter ?? filter;
     this.sqlScriptOptions  = sqlScriptOptions;
     embeddedScriptProvider = new EmbeddedScriptProvider(assembly, filter);
 }
        /// <summary>
        /// Initializes a new instance of the <see cref="EmbeddedScriptProvider"/> class.
        /// </summary>
        /// <param name="assembly">The assembly.</param>
        /// <param name="filter">The embedded sql script filter.</param>
        /// <param name="scriptOptions">Script options</param>
        public EmbeddedScriptAndCodeProvider(Assembly assembly, Func <string, bool> filter, ScriptOptions scriptOptions)
        {
            this.assembly          = assembly;
            this.filter            = filter;
            embeddedScriptProvider = new EmbeddedScriptProvider(assembly, filter);

            ScriptOptions = scriptOptions;
        }
Esempio n. 3
0
        public static EmbeddedScriptProvider GetEmbeddedScriptProvder(Assembly assembly)
        {
            Regex regex = new Regex(VERSION_REGEX);

            Func<string, bool> filter = (fileName) => regex.IsMatch(fileName);

            EmbeddedScriptProvider pro = new EmbeddedScriptProvider(assembly, filter);
            return pro;
        }
 /// <summary>
 /// Initializes a new instance of the <see cref="EmbeddedScriptProvider"/> class.
 /// </summary>
 /// <param name="assembly">The assembly.</param>
 /// <param name="filter">The embedded sql script filter.</param>
 public EmbeddedScriptAndCodeProvider(Assembly assembly, Func<string, bool> filter)
 {
     this.assembly = assembly;
     embeddedScriptProvider = new EmbeddedScriptProvider(assembly, filter);
 }
Esempio n. 5
0
 /// <summary>
 /// Initializes a new instance of the <see cref="EmbeddedScriptProvider"/> class.
 /// </summary>
 /// <param name="assembly">The assembly.</param>
 /// <param name="filter">The embedded sql script filter.</param>
 public EmbeddedScriptAndCodeProvider(Assembly assembly, Func <string, bool> filter)
 {
     this.assembly          = assembly;
     embeddedScriptProvider = new EmbeddedScriptProvider(assembly, filter);
 }