| Copyright | Copyright (C) 2005 John Goerzen |
|---|---|
| License | BSD-3-Clause |
| Maintainer | Philippe <philippedev101\@gmail.com> |
| Stability | provisional |
| Portability | portable |
| Safe Haskell | Safe-Inferred |
| Language | Haskell2010 |
Magic.Init
Description
Creating a magic handle and loading magic databases into it. A handle returned
by magicOpen must be given a database with magicLoadDefault or magicLoad
before it can be queried with the functions in Magic.Operations.
Written by John Goerzen.
Documentation
magicOpen :: [MagicFlag] -> IO Magic Source #
Create a new magic handle configured with the given flags (see
MagicFlag). Before querying anything you must load a database with
magicLoadDefault or magicLoad.
The handle is freed automatically when it is garbage-collected. Raises an
IOError if the handle cannot be created.