dawdle-0.1.0.2: Generates DDL suggestions based on a CSV file

Safe HaskellSafe
LanguageHaskell2010

Database.Dawdle.Options

Synopsis

Documentation

data Options Source

Options structure for passing to the main module's analyzeFile

Constructors

Options 

Fields

optVerbose :: Bool

Verbose mode

optInput :: Maybe FilePath

stdin (Nothing) or file to read (Just FilePath)

optStopAfter :: Maybe Int

Threshold for stopping (Just Int) or consume entire file (Nothing)

optWithHeader :: Bool

Is the first line a header? (Boolean)

optSepChar :: Char

Separator character for CSV (Default ',')

optVerifyIntegrity :: Bool

Verify integrity of CSV file first? (Default True)

Instances

getOpts :: [String] -> IO (Options, [String]) Source

getOpts constructs a set of flags based on the user's input and the default options set in the defaultOptions structure

defaultOptions :: Options Source

Default set of options:

  • Verbosity: False
  • Input: Nothing (stdin)
  • Stop after threshold: Just 10000
  • With header: False
  • Separator char: ,
  • Verify integrity: True