-- Hoogle documentation, generated by Haddock
-- See Hoogle, http://www.haskell.org/hoogle/
-- | PostgreSQL Schema Migrations
--
-- A PostgreSQL-simple schema migration utility
@package postgresql-simple-migration
@version 0.1.0.0
-- | Migration library for postgresql-simple.
module Database.PostgreSQL.Simple.Migration
-- | Executes migrations inside the provided MigrationContext.
runMigration :: MigrationContext -> IO (MigrationResult String)
-- | The MigrationContext provides an execution context for
-- migrations.
data MigrationContext
MigrationContext :: MigrationCommand -> Bool -> Connection -> MigrationContext
-- | The action that will be performed by runMigration
migrationContextCommand :: MigrationContext -> MigrationCommand
-- | Verbosity of the library.
migrationContextVerbose :: MigrationContext -> Bool
-- | The PostgreSQL connection to use for migrations.
migrationContextConnection :: MigrationContext -> Connection
-- | MigrationCommand determines the action of the
-- runMigration script.
data MigrationCommand
-- | Initializes the database with a helper table containing meta
-- information.
MigrationInitialization :: MigrationCommand
-- | Executes migrations based on SQL scripts in the provided
-- FilePath in alphabetical order.
MigrationDirectory :: FilePath -> MigrationCommand
-- | Executes a migration based on script located at the provided
-- FilePath.
MigrationFile :: ScriptName -> FilePath -> MigrationCommand
-- | Executes a migration based on the provided bytestring.
MigrationScript :: ScriptName -> ByteString -> MigrationCommand
-- | A sum-type denoting the result of a migration.
data MigrationResult a
-- | There was an error in script migration.
MigrationError :: a -> MigrationResult a
-- | All scripts have been executed successfully.
MigrationSuccess :: MigrationResult a
-- | The name of a script. Typically the filename or a custom name when
-- using Haskell migrations.
type ScriptName = String
instance Show MigrationCommand
instance Eq MigrationCommand
instance Read MigrationCommand
instance Ord MigrationCommand
instance Show CheckScriptResult
instance Eq CheckScriptResult
instance Read CheckScriptResult
instance Ord CheckScriptResult
instance Show a => Show (MigrationResult a)
instance Eq a => Eq (MigrationResult a)
instance Read a => Read (MigrationResult a)
instance Ord a => Ord (MigrationResult a)