Distribution.Types.ComponentName

Cabal-2.2.0.0: A framework for packaging Haskell software

Safe Haskell | None
Language | Haskell2010

Distribution.Types.ComponentName

Synopsis

- data ComponentName
  - = CLibName
  - | CSubLibName UnqualComponentName
  - | CFLibName UnqualComponentName
  - | CExeName UnqualComponentName
  - | CTestName UnqualComponentName
  - | CBenchName UnqualComponentName
- defaultLibName :: ComponentName
- libraryComponentName :: Maybe UnqualComponentName -> ComponentName
- showComponentName :: ComponentName -> String
- componentNameStanza :: ComponentName -> String
- componentNameString :: ComponentName -> Maybe UnqualComponentName

# Documentation

data ComponentName Source #

Constructors

CLibName |
CSubLibName UnqualComponentName |
CFLibName UnqualComponentName |
CExeName UnqualComponentName |
CTestName UnqualComponentName |
CBenchName UnqualComponentName |

Instances

Eq ComponentName Source # |
Instance details Methods (==) :: ComponentName -> ComponentName -> Bool # (/=) :: ComponentName -> ComponentName -> Bool #
Ord ComponentName Source # |
Instance details Methods compare :: ComponentName -> ComponentName -> Ordering # (<) :: ComponentName -> ComponentName -> Bool # (<=) :: ComponentName -> ComponentName -> Bool # (>) :: ComponentName -> ComponentName -> Bool # (>=) :: ComponentName -> ComponentName -> Bool # max :: ComponentName -> ComponentName -> ComponentName # min :: ComponentName -> ComponentName -> ComponentName #
Read ComponentName Source # |
Instance details Methods readsPrec :: Int -> ReadS ComponentName Source # readList :: ReadS [ComponentName] Source # readPrec :: ReadPrec ComponentName Source # readListPrec :: ReadPrec [ComponentName] Source #
Show ComponentName Source # |
Instance details Methods showsPrec :: Int -> ComponentName -> ShowS Source # show :: ComponentName -> String Source # showList :: [ComponentName] -> ShowS Source #
Generic ComponentName Source # |
Instance details Associated Types type Rep ComponentName :: * -> * Source # Methods from :: ComponentName -> Rep ComponentName x Source # to :: Rep ComponentName x -> ComponentName Source #
Binary ComponentName Source # |
Instance details Methods put :: ComponentName -> Put Source # get :: Get ComponentName Source # putList :: [ComponentName] -> Put Source #
Pretty ComponentName Source # |
Instance details Methods pretty :: ComponentName -> Doc Source #
Text ComponentName Source # |
Instance details Methods disp :: ComponentName -> Doc Source # parse :: ReadP r ComponentName Source #
type Rep ComponentName Source # |
Instance details type Rep ComponentName = D1 (MetaData "ComponentName" "Distribution.Types.ComponentName" "Cabal-2.2.0.0" False) ((C1 (MetaCons "CLibName" PrefixI False) (U1 :: * -> *) :+: (C1 (MetaCons "CSubLibName" PrefixI False) (S1 (MetaSel (Nothing :: Maybe Symbol) NoSourceUnpackedness NoSourceStrictness DecidedLazy) (Rec0 UnqualComponentName)) :+: C1 (MetaCons "CFLibName" PrefixI False) (S1 (MetaSel (Nothing :: Maybe Symbol) NoSourceUnpackedness NoSourceStrictness DecidedLazy) (Rec0 UnqualComponentName)))) :+: (C1 (MetaCons "CExeName" PrefixI False) (S1 (MetaSel (Nothing :: Maybe Symbol) NoSourceUnpackedness NoSourceStrictness DecidedLazy) (Rec0 UnqualComponentName)) :+: (C1 (MetaCons "CTestName" PrefixI False) (S1 (MetaSel (Nothing :: Maybe Symbol) NoSourceUnpackedness NoSourceStrictness DecidedLazy) (Rec0 UnqualComponentName)) :+: C1 (MetaCons "CBenchName" PrefixI False) (S1 (MetaSel (Nothing :: Maybe Symbol) NoSourceUnpackedness NoSourceStrictness DecidedLazy) (Rec0 UnqualComponentName)))))

defaultLibName :: ComponentName Source #

libraryComponentName :: Maybe UnqualComponentName -> ComponentName Source #

Convert the `UnqualComponentName` of a library into a `ComponentName`.

showComponentName :: ComponentName -> String Source #

componentNameStanza :: ComponentName -> String Source #

componentNameString :: ComponentName -> Maybe UnqualComponentName Source #

This gets the underlying unqualified component name. In fact, it is guaranteed to uniquely identify a component, returning `Nothing` if the `ComponentName` was for the public library.