MissingH-1.4.0.1: Large utility library

Copyright | Copyright (C) 2004-2011 John Goerzen
License | BSD3
Maintainer | John Goerzen <jgoerzen@complete.org>
Stability | provisional
Portability | portable
Safe Haskell | None
Language | Haskell98

System.IO.HVFS.Combinators

Contents

- Restrictions

Description

Support for combining different HVFS modules together

Copyright (c) 2004-2005 John Goerzen, jgoerzen@complete.org

Synopsis

- data HVFS a => HVFSReadOnly a = HVFSReadOnly a
- data HVFS a => HVFSChroot a
- newHVFSChroot :: HVFS a => a -> FilePath -> IO (HVFSChroot a)

# Restrictions

data HVFS a => HVFSReadOnly a #

Restrict access to the underlying filesystem to be strictly read-only. Any write-type operations will cause an error.

No constructor is required; just say `HVFSReadOnly fs` to make a new read-only wrapper around the `HVFS` instance `fs`.

Constructors

HVFSReadOnly a |

Instances

(Eq a, HVFS a) => Eq (HVFSReadOnly a) # |
Methods (==) :: HVFSReadOnly a -> HVFSReadOnly a -> Bool # (/=) :: HVFSReadOnly a -> HVFSReadOnly a -> Bool #
HVFS a => Show (HVFSReadOnly a) # |
Methods showsPrec :: Int -> HVFSReadOnly a -> ShowS # show :: HVFSReadOnly a -> String # showList :: [HVFSReadOnly a] -> ShowS #
HVFSOpenable a => HVFSOpenable (HVFSReadOnly a) # |
Methods vOpen :: HVFSReadOnly a -> FilePath -> IOMode -> IO HVFSOpenEncap # vReadFile :: HVFSReadOnly a -> FilePath -> IO String # vWriteFile :: HVFSReadOnly a -> FilePath -> String -> IO () # vOpenBinaryFile :: HVFSReadOnly a -> FilePath -> IOMode -> IO HVFSOpenEncap #
HVFS a => HVFS (HVFSReadOnly a) # |
Methods vGetCurrentDirectory :: HVFSReadOnly a -> IO FilePath # vSetCurrentDirectory :: HVFSReadOnly a -> FilePath -> IO () # vGetDirectoryContents :: HVFSReadOnly a -> FilePath -> IO [FilePath] # vDoesFileExist :: HVFSReadOnly a -> FilePath -> IO Bool # vDoesDirectoryExist :: HVFSReadOnly a -> FilePath -> IO Bool # vDoesExist :: HVFSReadOnly a -> FilePath -> IO Bool # vCreateDirectory :: HVFSReadOnly a -> FilePath -> IO () # vRemoveDirectory :: HVFSReadOnly a -> FilePath -> IO () # vRenameDirectory :: HVFSReadOnly a -> FilePath -> FilePath -> IO () # vRemoveFile :: HVFSReadOnly a -> FilePath -> IO () # vRenameFile :: HVFSReadOnly a -> FilePath -> FilePath -> IO () # vGetFileStatus :: HVFSReadOnly a -> FilePath -> IO HVFSStatEncap # vGetSymbolicLinkStatus :: HVFSReadOnly a -> FilePath -> IO HVFSStatEncap # vGetModificationTime :: HVFSReadOnly a -> FilePath -> IO ClockTime # vRaiseError :: HVFSReadOnly a -> IOErrorType -> String -> Maybe FilePath -> IO c # vCreateSymbolicLink :: HVFSReadOnly a -> FilePath -> FilePath -> IO () # vReadSymbolicLink :: HVFSReadOnly a -> FilePath -> IO FilePath # vCreateLink :: HVFSReadOnly a -> FilePath -> FilePath -> IO () #

data HVFS a => HVFSChroot a #

Access a subdirectory of a real filesystem as if it was the root of that filesystem.

Instances

(Eq a, HVFS a) => Eq (HVFSChroot a) # |
Methods (==) :: HVFSChroot a -> HVFSChroot a -> Bool # (/=) :: HVFSChroot a -> HVFSChroot a -> Bool #
HVFS a => Show (HVFSChroot a) # |
Methods showsPrec :: Int -> HVFSChroot a -> ShowS # show :: HVFSChroot a -> String # showList :: [HVFSChroot a] -> ShowS #
HVFSOpenable a => HVFSOpenable (HVFSChroot a) # |
Methods vOpen :: HVFSChroot a -> FilePath -> IOMode -> IO HVFSOpenEncap # vReadFile :: HVFSChroot a -> FilePath -> IO String # vWriteFile :: HVFSChroot a -> FilePath -> String -> IO () # vOpenBinaryFile :: HVFSChroot a -> FilePath -> IOMode -> IO HVFSOpenEncap #
HVFS a => HVFS (HVFSChroot a) # |
Methods vGetCurrentDirectory :: HVFSChroot a -> IO FilePath # vSetCurrentDirectory :: HVFSChroot a -> FilePath -> IO () # vGetDirectoryContents :: HVFSChroot a -> FilePath -> IO [FilePath] # vDoesFileExist :: HVFSChroot a -> FilePath -> IO Bool # vDoesDirectoryExist :: HVFSChroot a -> FilePath -> IO Bool # vDoesExist :: HVFSChroot a -> FilePath -> IO Bool # vCreateDirectory :: HVFSChroot a -> FilePath -> IO () # vRemoveDirectory :: HVFSChroot a -> FilePath -> IO () # vRenameDirectory :: HVFSChroot a -> FilePath -> FilePath -> IO () # vRemoveFile :: HVFSChroot a -> FilePath -> IO () # vRenameFile :: HVFSChroot a -> FilePath -> FilePath -> IO () # vGetFileStatus :: HVFSChroot a -> FilePath -> IO HVFSStatEncap # vGetSymbolicLinkStatus :: HVFSChroot a -> FilePath -> IO HVFSStatEncap # vGetModificationTime :: HVFSChroot a -> FilePath -> IO ClockTime # vRaiseError :: HVFSChroot a -> IOErrorType -> String -> Maybe FilePath -> IO c # vCreateSymbolicLink :: HVFSChroot a -> FilePath -> FilePath -> IO () # vReadSymbolicLink :: HVFSChroot a -> FilePath -> IO FilePath # vCreateLink :: HVFSChroot a -> FilePath -> FilePath -> IO () #

newHVFSChroot #

Arguments

:: HVFS a |
=> a | The object to pass requests on to
-> FilePath | The path of the directory to make root
-> IO (HVFSChroot a) | The resulting new object

Create a new `HVFSChroot` object.