Safe Haskell | None |
---|---|
Language | Haskell2010 |
System.Nix.ContentAddress
Documentation
data ContentAddress Source #
An address for a content-addressable store path, i.e. one whose store path hash is purely a function of its contents (as opposed to paths that are derivation outputs, whose hashes are a function of the contents of the derivation file instead).
For backwards-compatibility reasons, the same information is encodable in multiple ways, depending on the method used to add the path to the store. These unfortunately result in separate store paths.
Instances
data ContentAddressMethod Source #
Instances
Generic ContentAddressMethod Source # | |||||
Defined in System.Nix.ContentAddress Associated Types
Methods from :: ContentAddressMethod -> Rep ContentAddressMethod x # to :: Rep ContentAddressMethod x -> ContentAddressMethod # | |||||
Show ContentAddressMethod Source # | |||||
Defined in System.Nix.ContentAddress Methods showsPrec :: Int -> ContentAddressMethod -> ShowS # show :: ContentAddressMethod -> String # showList :: [ContentAddressMethod] -> ShowS # | |||||
Eq ContentAddressMethod Source # | |||||
Defined in System.Nix.ContentAddress Methods (==) :: ContentAddressMethod -> ContentAddressMethod -> Bool # (/=) :: ContentAddressMethod -> ContentAddressMethod -> Bool # | |||||
Ord ContentAddressMethod Source # | |||||
Defined in System.Nix.ContentAddress Methods compare :: ContentAddressMethod -> ContentAddressMethod -> Ordering # (<) :: ContentAddressMethod -> ContentAddressMethod -> Bool # (<=) :: ContentAddressMethod -> ContentAddressMethod -> Bool # (>) :: ContentAddressMethod -> ContentAddressMethod -> Bool # (>=) :: ContentAddressMethod -> ContentAddressMethod -> Bool # max :: ContentAddressMethod -> ContentAddressMethod -> ContentAddressMethod # min :: ContentAddressMethod -> ContentAddressMethod -> ContentAddressMethod # | |||||
type Rep ContentAddressMethod Source # | |||||
Defined in System.Nix.ContentAddress type Rep ContentAddressMethod = D1 ('MetaData "ContentAddressMethod" "System.Nix.ContentAddress" "hnix-store-core-0.8.0.0-FTqw4iIy5sQBH9BMZeLljI" 'False) (C1 ('MetaCons "FileIngestionMethod" 'PrefixI 'False) (S1 ('MetaSel ('Nothing :: Maybe Symbol) 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 FileIngestionMethod)) :+: C1 ('MetaCons "TextIngestionMethod" 'PrefixI 'False) (U1 :: Type -> Type)) |
data FileIngestionMethod Source #
Add path recursively or not
Instances
Bounded FileIngestionMethod Source # | |||||
Defined in System.Nix.Store.Types | |||||
Enum FileIngestionMethod Source # | |||||
Defined in System.Nix.Store.Types Methods succ :: FileIngestionMethod -> FileIngestionMethod # pred :: FileIngestionMethod -> FileIngestionMethod # toEnum :: Int -> FileIngestionMethod # fromEnum :: FileIngestionMethod -> Int # enumFrom :: FileIngestionMethod -> [FileIngestionMethod] # enumFromThen :: FileIngestionMethod -> FileIngestionMethod -> [FileIngestionMethod] # enumFromTo :: FileIngestionMethod -> FileIngestionMethod -> [FileIngestionMethod] # enumFromThenTo :: FileIngestionMethod -> FileIngestionMethod -> FileIngestionMethod -> [FileIngestionMethod] # | |||||
Generic FileIngestionMethod Source # | |||||
Defined in System.Nix.Store.Types Associated Types
Methods from :: FileIngestionMethod -> Rep FileIngestionMethod x # to :: Rep FileIngestionMethod x -> FileIngestionMethod # | |||||
Show FileIngestionMethod Source # | |||||
Defined in System.Nix.Store.Types Methods showsPrec :: Int -> FileIngestionMethod -> ShowS # show :: FileIngestionMethod -> String # showList :: [FileIngestionMethod] -> ShowS # | |||||
Eq FileIngestionMethod Source # | |||||
Defined in System.Nix.Store.Types Methods (==) :: FileIngestionMethod -> FileIngestionMethod -> Bool # (/=) :: FileIngestionMethod -> FileIngestionMethod -> Bool # | |||||
Ord FileIngestionMethod Source # | |||||
Defined in System.Nix.Store.Types Methods compare :: FileIngestionMethod -> FileIngestionMethod -> Ordering # (<) :: FileIngestionMethod -> FileIngestionMethod -> Bool # (<=) :: FileIngestionMethod -> FileIngestionMethod -> Bool # (>) :: FileIngestionMethod -> FileIngestionMethod -> Bool # (>=) :: FileIngestionMethod -> FileIngestionMethod -> Bool # max :: FileIngestionMethod -> FileIngestionMethod -> FileIngestionMethod # min :: FileIngestionMethod -> FileIngestionMethod -> FileIngestionMethod # | |||||
type Rep FileIngestionMethod Source # | |||||
Defined in System.Nix.Store.Types type Rep FileIngestionMethod = D1 ('MetaData "FileIngestionMethod" "System.Nix.Store.Types" "hnix-store-core-0.8.0.0-FTqw4iIy5sQBH9BMZeLljI" 'False) (C1 ('MetaCons "FileIngestionMethod_Flat" 'PrefixI 'False) (U1 :: Type -> Type) :+: C1 ('MetaCons "FileIngestionMethod_FileRecursive" 'PrefixI 'False) (U1 :: Type -> Type)) |
contentAddressParser :: Parser ContentAddress Source #
Parser for content addressable field
buildContentAddress :: ContentAddress -> Text Source #
Marshall ContentAddressableAddress
to Text
in form suitable for remote protocol usage.
parseContentAddress :: Text -> Either String ContentAddress Source #
Parse ContentAddressableAddress
from ByteString