Distribution.Types.PackageId.Lens
data PackageIdentifier Source #
The name and version of a package.
Defined in Distribution.Types.PackageId
Methods
(==) :: PackageIdentifier -> PackageIdentifier -> Bool Source #
(/=) :: PackageIdentifier -> PackageIdentifier -> Bool Source #
gfoldl :: ( forall d b. Data d => c (d -> b) -> d -> c b) -> ( forall g. g -> c g) -> PackageIdentifier -> c PackageIdentifier Source #
gunfold :: ( forall b r. Data b => c (b -> r) -> c r) -> ( forall r. r -> c r) -> Constr -> c PackageIdentifier Source #
toConstr :: PackageIdentifier -> Constr Source #
dataTypeOf :: PackageIdentifier -> DataType Source #
dataCast1 :: Typeable t => ( forall d. Data d => c (t d)) -> Maybe (c PackageIdentifier ) Source #
dataCast2 :: Typeable t => ( forall d e. ( Data d, Data e) => c (t d e)) -> Maybe (c PackageIdentifier ) Source #
gmapT :: ( forall b. Data b => b -> b) -> PackageIdentifier -> PackageIdentifier Source #
gmapQl :: (r -> r' -> r) -> r -> ( forall d. Data d => d -> r') -> PackageIdentifier -> r Source #
gmapQr :: forall r r'. (r' -> r -> r) -> r -> ( forall d. Data d => d -> r') -> PackageIdentifier -> r Source #
gmapQ :: ( forall d. Data d => d -> u) -> PackageIdentifier -> [u] Source #
gmapQi :: Int -> ( forall d. Data d => d -> u) -> PackageIdentifier -> u Source #
gmapM :: Monad m => ( forall d. Data d => d -> m d) -> PackageIdentifier -> m PackageIdentifier Source #
gmapMp :: MonadPlus m => ( forall d. Data d => d -> m d) -> PackageIdentifier -> m PackageIdentifier Source #
gmapMo :: MonadPlus m => ( forall d. Data d => d -> m d) -> PackageIdentifier -> m PackageIdentifier Source #
compare :: PackageIdentifier -> PackageIdentifier -> Ordering Source #
(<) :: PackageIdentifier -> PackageIdentifier -> Bool Source #
(<=) :: PackageIdentifier -> PackageIdentifier -> Bool Source #
(>) :: PackageIdentifier -> PackageIdentifier -> Bool Source #
(>=) :: PackageIdentifier -> PackageIdentifier -> Bool Source #
max :: PackageIdentifier -> PackageIdentifier -> PackageIdentifier Source #
min :: PackageIdentifier -> PackageIdentifier -> PackageIdentifier Source #
readsPrec :: Int -> ReadS PackageIdentifier Source #
readList :: ReadS [ PackageIdentifier ] Source #
readPrec :: ReadPrec PackageIdentifier Source #
readListPrec :: ReadPrec [ PackageIdentifier ] Source #
showsPrec :: Int -> PackageIdentifier -> ShowS Source #
show :: PackageIdentifier -> String Source #
showList :: [ PackageIdentifier ] -> ShowS Source #
Associated Types
type Rep PackageIdentifier :: Type -> Type Source #
from :: PackageIdentifier -> Rep PackageIdentifier x Source #
to :: Rep PackageIdentifier x -> PackageIdentifier Source #
put :: PackageIdentifier -> Put Source #
get :: Get PackageIdentifier Source #
putList :: [ PackageIdentifier ] -> Put Source #
rnf :: PackageIdentifier -> () Source #
structure :: Proxy PackageIdentifier -> Structure Source #
structureHash' :: Tagged PackageIdentifier MD5
pretty :: PackageIdentifier -> Doc Source #
prettyVersioned :: CabalSpecVersion -> PackageIdentifier -> Doc Source #
>>> simpleParsec "foo-bar-0" :: Maybe PackageIdentifier Just (PackageIdentifier {pkgName = PackageName "foo-bar", pkgVersion = mkVersion [0]})
>>>
simpleParsec "foo-bar-0" :: Maybe PackageIdentifier
>>> simpleParsec "foo-bar" :: Maybe PackageIdentifier Just (PackageIdentifier {pkgName = PackageName "foo-bar", pkgVersion = mkVersion []})
simpleParsec "foo-bar" :: Maybe PackageIdentifier
Note: Stricter than Text instance
Text
>>> simpleParsec "foo-bar-0-0" :: Maybe PackageIdentifier Nothing
simpleParsec "foo-bar-0-0" :: Maybe PackageIdentifier
>>> simpleParsec "foo-bar.0" :: Maybe PackageIdentifier Nothing
simpleParsec "foo-bar.0" :: Maybe PackageIdentifier
>>> simpleParsec "foo-bar.4-2" :: Maybe PackageIdentifier Nothing
simpleParsec "foo-bar.4-2" :: Maybe PackageIdentifier
>>> simpleParsec "1.2.3" :: Maybe PackageIdentifier Nothing
simpleParsec "1.2.3" :: Maybe PackageIdentifier
parsec :: CabalParsing m => m PackageIdentifier Source #
Defined in Distribution.Package
packageId :: PackageIdentifier -> PackageIdentifier Source #
pkgName :: Lens' PackageIdentifier PackageName Source #
pkgVersion :: Lens' PackageIdentifier Version Source #