internal static IDatabaseDeployer CreateDatabaseDeployerFromElement(DatabaseDeploymentElement element)
        {
            if (element != null && element.ElementInformation != null && element.ElementInformation.IsPresent)
            {
                element.Type.ThrowIfNullOrEmpty <InvalidOperationException>("Deployer is null or empty");

                Type type = Type.GetType(element.Type, true);
                return((IDatabaseDeployer)Activator.CreateInstance(type));
            }
            else
            {
                return(null);
            }
        }
 internal static DatabaseDeployment CreateDatabaseDeploymentFromElement(DatabaseDeploymentElement element, ConnectionContext connectionContext)
 {
     if (element != null && element.ElementInformation != null && element.ElementInformation.IsPresent)
     {
         return(new DatabaseDeployment
         {
             ConnectionContext = connectionContext,
             CreateUniqueDatabaseName = element.CreateUniqueDatabaseName,
             DropDatabaseOnExit = element.DropDatabaseOnExit,
             DatabaseDeployer = CreateDatabaseDeployerFromElement(element),
             DeployerConfig = CreateDeployerConfigFromElement(element.DeployerConfig, element.Type)
         });
     }
     else
     {
         return(null);
     }
 }