SqlScripter.Core/src/Smo/SmoScriptingUtil.cs
/// <summary>
/// Scripting collection of Iscriptable's 
/// ver. for scripting to single file
/// </summary>
/// <param name="collection"></param>
Scripting collection of Iscriptable's
ver. for scripting to single file
Scripting collection of Iscriptable ' s ver . for scripting to single file
public static void ScriptSchemas(ICollection collection, StreamWriter writer, ScriptingOptions options, bool printObjectsCount) {
            if (printObjectsCount) {
                log.InfoFormat("Script: {0} in schemas collection ", collection.Count);
            }
            foreach (Microsoft.SqlServer.Management.Smo.Schema schema in collection) {
                string script = @"CREATE SCHEMA [{0}] AUTHORIZATION [dbo]";
                script = string.Format(script, schema.Name);
                Write(script, writer);
            }
        }
public static void ScriptSchemas ( ICollection collection , StreamWriter writer , ScriptingOptions options , bool printObjectsCount ) { if ( printObjectsCount ) { log . InfoFormat ( " " , collection . Count ) ; } foreach ( Microsoft . SqlServer . Management . Smo . Schema schema in collection ) { string script = @"CREATE SCHEMA [{0}] AUTHORIZATION [dbo]" ; script = string . Format ( script , schema . Name ) ; Write ( script , writer ) ; } }
Scripting collection of Iscriptable's
ver.
Scripting collection of Iscriptable ' s ver .
collection
ICollection
None
writer
StreamWriter
options
ScriptingOptions
printObjectsCount
bool