propellor-5.10.1: property-based host configuration management in haskell

Safe HaskellNone
LanguageHaskell98

Propellor

Contents

Description

When propellor runs on a Host, it ensures that its Properties are satisfied, taking action as necessary when a Property is not currently satisfied.

A simple propellor program example:

import Propellor
import qualified Propellor.Property.File as File
import qualified Propellor.Property.Apt as Apt

main :: IO ()
main = defaultMain hosts

hosts :: [Host]
hosts = [example]

example :: Host
example = host "example.com" $ props
    & Apt.installed ["mydaemon"]
    & "/etc/mydaemon.conf" `File.containsLine` "secure=1"
      `onChange` cmdProperty "service" ["mydaemon", "restart"]
    ! Apt.installed ["unwantedpackage"]

See config.hs for a more complete example, and clone Propellor's git repository for a deployable system using Propellor: git clone git://git.joeyh.name/propellor

Synopsis

Core data types

data Host Source #

Everything Propellor knows about a system: Its hostname, properties and their collected info.

Constructors

Host 
Instances
Show Host Source # 
Instance details

Defined in Propellor.Types.Core

Methods

showsPrec :: Int -> Host -> ShowS

show :: Host -> String

showList :: [Host] -> ShowS

IsContainer Host Source # 
Instance details

Defined in Propellor.Container

Conductable Host Source # 
Instance details

Defined in Propellor.Property.Conductor

MonadReader Host Propellor Source # 
Instance details

Defined in Propellor.Types.Core

Methods

ask :: Propellor Host

local :: (Host -> Host) -> Propellor a -> Propellor a

reader :: (Host -> a) -> Propellor a

Conductable [Host] Source # 
Instance details

Defined in Propellor.Property.Conductor

data Property metatypes Source #

The core data type of Propellor, this represents a property that the system should have, with a description, and an action to ensure it has the property.

There are different types of properties that target different OS's, and so have different metatypes. For example: "Property DebianLike" and "Property FreeBSD".

Also, some properties have associated Info, which is indicated in their type: "Property (HasInfo + DebianLike)"

There are many associated type families, which are mostly used internally, so you needn't worry about them.

Instances
TightenTargets Property Source # 
Instance details

Defined in Propellor.Types

Methods

tightenTargets :: (TightenTargetsAllowed untightened tightened, SingI tightened) => Property (MetaTypes untightened) -> Property (MetaTypes tightened) Source #

Checkable Property i Source # 
Instance details

Defined in Propellor.Types.ResultCheck

Show (Property metatypes) Source # 
Instance details

Defined in Propellor.Types

Methods

showsPrec :: Int -> Property metatypes -> ShowS

show :: Property metatypes -> String

showList :: [Property metatypes] -> ShowS

SingI metatypes => Semigroup (Property (MetaTypes metatypes)) Source #

Any type of Property is a Semigroup. When properties x and y are appended together, the resulting property has a description like "x and y". Note that when x fails to be ensured, it will not try to ensure y.

Instance details

Defined in Propellor.Types

Methods

(<>) :: Property (MetaTypes metatypes) -> Property (MetaTypes metatypes) -> Property (MetaTypes metatypes) #

sconcat :: NonEmpty (Property (MetaTypes metatypes)) -> Property (MetaTypes metatypes)

stimes :: Integral b => b -> Property (MetaTypes metatypes) -> Property (MetaTypes metatypes)

SingI metatypes => Monoid (Property (MetaTypes metatypes)) Source #

Any type of Property is a Monoid.

Instance details

Defined in Propellor.Types

Methods

mempty :: Property (MetaTypes metatypes) #

mappend :: Property (MetaTypes metatypes) -> Property (MetaTypes metatypes) -> Property (MetaTypes metatypes) #

mconcat :: [Property (MetaTypes metatypes)] -> Property (MetaTypes metatypes) #

IsProp (Property metatypes) Source # 
Instance details

Defined in Propellor.Types

Methods

setDesc :: Property metatypes -> Desc -> Property metatypes Source #

getDesc :: Property metatypes -> Desc Source #

getChildren :: Property metatypes -> [ChildProperty] Source #

addChildren :: Property metatypes -> [ChildProperty] -> Property metatypes Source #

getInfoRecursive :: Property metatypes -> Info Source #

getInfo :: Property metatypes -> Info Source #

toChildProperty :: Property metatypes -> ChildProperty Source #

getSatisfy :: Property metatypes -> Maybe (Propellor Result) Source #

(CheckCombinable x y, SingI (Combine x y)) => Combines (Property (MetaTypes x)) (Property (MetaTypes y)) Source # 
Instance details

Defined in Propellor.Types

(CheckCombinable x y, SingI (Combine x y)) => Combines (Property (MetaTypes x)) (RevertableProperty (MetaTypes y) (MetaTypes y')) Source # 
Instance details

Defined in Propellor.Types

(CheckCombinable x y, SingI (Combine x y)) => Combines (RevertableProperty (MetaTypes x) (MetaTypes x')) (Property (MetaTypes y)) Source # 
Instance details

Defined in Propellor.Types

data RevertableProperty setupmetatypes undometatypes Source #

A property that can be reverted. The first Property is run normally and the second is run when it's reverted.

See Versioned for a way to use RevertableProperty to define different versions of a host.

Instances
(CheckCombinable x y, SingI (Combine x y)) => Combines (Property (MetaTypes x)) (RevertableProperty (MetaTypes y) (MetaTypes y')) Source # 
Instance details

Defined in Propellor.Types

Show (RevertableProperty setupmetatypes undometatypes) Source # 
Instance details

Defined in Propellor.Types

Methods

showsPrec :: Int -> RevertableProperty setupmetatypes undometatypes -> ShowS

show :: RevertableProperty setupmetatypes undometatypes -> String

showList :: [RevertableProperty setupmetatypes undometatypes] -> ShowS

(Semigroup (Property (MetaTypes setupmetatypes)), Semigroup (Property (MetaTypes undometatypes)), SingI setupmetatypes, SingI undometatypes) => Semigroup (RevertableProperty (MetaTypes setupmetatypes) (MetaTypes undometatypes)) Source #

Any type of RevertableProperty is a Semigroup. When revertable properties x and y are appended together, the resulting revertable property has a description like "x and y". Note that when x fails to be ensured, it will not try to ensure y.

Instance details

Defined in Propellor.Types

Methods

(<>) :: RevertableProperty (MetaTypes setupmetatypes) (MetaTypes undometatypes) -> RevertableProperty (MetaTypes setupmetatypes) (MetaTypes undometatypes) -> RevertableProperty (MetaTypes setupmetatypes) (MetaTypes undometatypes) #

sconcat :: NonEmpty (RevertableProperty (MetaTypes setupmetatypes) (MetaTypes undometatypes)) -> RevertableProperty (MetaTypes setupmetatypes) (MetaTypes undometatypes)

stimes :: Integral b => b -> RevertableProperty (MetaTypes setupmetatypes) (MetaTypes undometatypes) -> RevertableProperty (MetaTypes setupmetatypes) (MetaTypes undometatypes)

(Monoid (Property (MetaTypes setupmetatypes)), Monoid (Property (MetaTypes undometatypes)), SingI setupmetatypes, SingI undometatypes) => Monoid (RevertableProperty (MetaTypes setupmetatypes) (MetaTypes undometatypes)) Source # 
Instance details

Defined in Propellor.Types

Methods

mempty :: RevertableProperty (MetaTypes setupmetatypes) (MetaTypes undometatypes) #

mappend :: RevertableProperty (MetaTypes setupmetatypes) (MetaTypes undometatypes) -> RevertableProperty (MetaTypes setupmetatypes) (MetaTypes undometatypes) -> RevertableProperty (MetaTypes setupmetatypes) (MetaTypes undometatypes) #

mconcat :: [RevertableProperty (MetaTypes setupmetatypes) (MetaTypes undometatypes)] -> RevertableProperty (MetaTypes setupmetatypes) (MetaTypes undometatypes) #

IsProp (RevertableProperty setupmetatypes undometatypes) Source # 
Instance details

Defined in Propellor.Types

Methods

setDesc :: RevertableProperty setupmetatypes undometatypes -> Desc -> RevertableProperty setupmetatypes undometatypes Source #

getDesc :: RevertableProperty setupmetatypes undometatypes -> Desc Source #

getChildren :: RevertableProperty setupmetatypes undometatypes -> [ChildProperty] Source #

addChildren :: RevertableProperty setupmetatypes undometatypes -> [ChildProperty] -> RevertableProperty setupmetatypes undometatypes Source #

getInfoRecursive :: RevertableProperty setupmetatypes undometatypes -> Info Source #

getInfo :: RevertableProperty setupmetatypes undometatypes -> Info Source #

toChildProperty :: RevertableProperty setupmetatypes undometatypes -> ChildProperty Source #

getSatisfy :: RevertableProperty setupmetatypes undometatypes -> Maybe (Propellor Result) Source #

(CheckCombinable x y, SingI (Combine x y)) => Combines (RevertableProperty (MetaTypes x) (MetaTypes x')) (Property (MetaTypes y)) Source # 
Instance details

Defined in Propellor.Types

(CheckCombinable x y, CheckCombinable x' y', SingI (Combine x y), SingI (Combine x' y')) => Combines (RevertableProperty (MetaTypes x) (MetaTypes x')) (RevertableProperty (MetaTypes y) (MetaTypes y')) Source # 
Instance details

Defined in Propellor.Types

Config file

defaultMain :: [Host] -> IO () Source #

Runs propellor on hosts, as controlled by command-line options.

host :: HostName -> Props metatypes -> Host Source #

Defines a host and its properties.

host "example.com" $ props
	& someproperty
	! oldproperty
	& otherproperty

(&) :: (IsProp p, MetaTypes y ~ GetMetaTypes p, CheckCombinableNote x y (NoteFor (Text "&"))) => Props (MetaTypes x) -> p -> Props (MetaTypes (Combine x y)) infixl 1 Source #

Adds a property to a Props.

Can add Properties and RevertableProperties

(!) :: CheckCombinableNote x z (NoteFor (Text "!")) => Props (MetaTypes x) -> RevertableProperty (MetaTypes y) (MetaTypes z) -> Props (MetaTypes (Combine x z)) infixl 1 Source #

Adds a property in reverted form.

Propertries

Properties are often combined together in your propellor configuration. For example:

"/etc/foo/config" `File.containsLine` "bar=1"
	`requires` File.dirExists "/etc/foo"

requires :: Combines x y => x -> y -> CombinedType x y Source #

Indicates that the first property depends on the second, so before the first is ensured, the second must be ensured.

The combined property uses the description of the first property.

before :: Combines x y => x -> y -> CombinedType x y Source #

Combines together two properties, resulting in one property that ensures the first, and if the first succeeds, ensures the second.

The combined property uses the description of the first property.

onChange :: Combines x y => x -> y -> CombinedType x y Source #

Whenever a change has to be made for a Property, causes a hook Property to also be run, but not otherwise.

describe :: IsProp p => p -> Desc -> p Source #

Changes the description of a property.

Everything you need to build your own properties, and useful property combinators

Properties to run shell commands

Properties that set Info

Combining a list of properties into a single property

Private data access for properties

fromString :: IsString a => String -> a #

(<>) :: Semigroup a => a -> a -> a #

class Semigroup a => Monoid a where #

Minimal complete definition

mempty

Methods

mempty :: a #

mappend :: a -> a -> a #

mconcat :: [a] -> a #

Instances
Monoid Ordering 
Instance details

Defined in GHC.Base

Methods

mempty :: Ordering #

mappend :: Ordering -> Ordering -> Ordering #

mconcat :: [Ordering] -> Ordering #

Monoid () 
Instance details

Defined in GHC.Base

Methods

mempty :: () #

mappend :: () -> () -> () #

mconcat :: [()] -> () #

Monoid Any 
Instance details

Defined in Data.Semigroup.Internal

Methods

mempty :: Any #

mappend :: Any -> Any -> Any #

mconcat :: [Any] -> Any #

Monoid All 
Instance details

Defined in Data.Semigroup.Internal

Methods

mempty :: All #

mappend :: All -> All -> All #

mconcat :: [All] -> All #

Monoid Info Source # 
Instance details

Defined in Propellor.Types.Info

Methods

mempty :: Info #

mappend :: Info -> Info -> Info #

mconcat :: [Info] -> Info #

Monoid Result Source # 
Instance details

Defined in Propellor.Types.Result

Monoid Doc 
Instance details

Defined in Text.PrettyPrint.HughesPJ

Methods

mempty :: Doc #

mappend :: Doc -> Doc -> Doc #

mconcat :: [Doc] -> Doc #

Monoid ByteString 
Instance details

Defined in Data.ByteString.Internal

Methods

mempty :: ByteString #

mappend :: ByteString -> ByteString -> ByteString #

mconcat :: [ByteString] -> ByteString #

Monoid ByteString 
Instance details

Defined in Data.ByteString.Lazy.Internal

Methods

mempty :: ByteString #

mappend :: ByteString -> ByteString -> ByteString #

mconcat :: [ByteString] -> ByteString #

Monoid IntSet 
Instance details

Defined in Data.IntSet.Internal

Methods

mempty :: IntSet #

mappend :: IntSet -> IntSet -> IntSet #

mconcat :: [IntSet] -> IntSet #

Monoid NamedConfMap Source # 
Instance details

Defined in Propellor.Types.Dns

Monoid DnsInfoUnpropagated Source # 
Instance details

Defined in Propellor.Types.Dns

Monoid DnsInfoPropagated Source # 
Instance details

Defined in Propellor.Types.Dns

Monoid AliasesInfo Source # 
Instance details

Defined in Propellor.Types.Dns

Monoid DockerInfo Source # 
Instance details

Defined in Propellor.Types.Docker

Monoid ChrootCfg Source # 
Instance details

Defined in Propellor.Types.Chroot

Monoid ChrootInfo Source # 
Instance details

Defined in Propellor.Types.Chroot

Monoid PrivInfo Source # 
Instance details

Defined in Propellor.PrivData

Monoid PkgUpgrade Source # 
Instance details

Defined in Propellor.Property.FreeBSD.Pkg

Monoid PkgUpdate Source # 
Instance details

Defined in Propellor.Property.FreeBSD.Pkg

Monoid PoudriereConfigured Source # 
Instance details

Defined in Propellor.Property.FreeBSD.Poudriere

Monoid PartSize Source # 
Instance details

Defined in Propellor.Property.Parted.Types

Monoid PartTable Source # 
Instance details

Defined in Propellor.Property.Parted.Types

Monoid Rules Source # 
Instance details

Defined in Propellor.Property.Firewall

Methods

mempty :: Rules #

mappend :: Rules -> Rules -> Rules #

mconcat :: [Rules] -> Rules #

Monoid Limit Source # 
Instance details

Defined in Propellor.Property.Ccache

Methods

mempty :: Limit #

mappend :: Limit -> Limit -> Limit #

mconcat :: [Limit] -> Limit #

Monoid MountOpts Source # 
Instance details

Defined in Propellor.Property.Mount

Monoid DiskPart Source # 
Instance details

Defined in Propellor.Property.Parted

Monoid PartLocation Source # 
Instance details

Defined in Propellor.Property.DiskImage.PartSpec

Monoid PartInfo Source # 
Instance details

Defined in Propellor.Property.DiskImage.PartSpec

Monoid DebootstrapConfig Source # 
Instance details

Defined in Propellor.Property.Debootstrap

Monoid TargetFilled Source # 
Instance details

Defined in Propellor.Property.Installer.Target

Monoid [a] 
Instance details

Defined in GHC.Base

Methods

mempty :: [a] #

mappend :: [a] -> [a] -> [a] #

mconcat :: [[a]] -> [a] #

Semigroup a => Monoid (Maybe a) 
Instance details

Defined in GHC.Base

Methods

mempty :: Maybe a #

mappend :: Maybe a -> Maybe a -> Maybe a #

mconcat :: [Maybe a] -> Maybe a #

Monoid a => Monoid (IO a) 
Instance details

Defined in GHC.Base

Methods

mempty :: IO a #

mappend :: IO a -> IO a -> IO a #

mconcat :: [IO a] -> IO a #

Monoid p => Monoid (Par1 p) 
Instance details

Defined in GHC.Generics

Methods

mempty :: Par1 p #

mappend :: Par1 p -> Par1 p -> Par1 p #

mconcat :: [Par1 p] -> Par1 p #

Ord a => Monoid (Set a) 
Instance details

Defined in Data.Set.Internal

Methods

mempty :: Set a #

mappend :: Set a -> Set a -> Set a #

mconcat :: [Set a] -> Set a #

Monoid (MergeSet a) 
Instance details

Defined in Data.Set.Internal

Methods

mempty :: MergeSet a #

mappend :: MergeSet a -> MergeSet a -> MergeSet a #

mconcat :: [MergeSet a] -> MergeSet a #

Monoid a => Monoid (Identity a) 
Instance details

Defined in Data.Functor.Identity

Methods

mempty :: Identity a #

mappend :: Identity a -> Identity a -> Identity a #

mconcat :: [Identity a] -> Identity a #

Monoid a => Monoid (Dual a) 
Instance details

Defined in Data.Semigroup.Internal

Methods

mempty :: Dual a #

mappend :: Dual a -> Dual a -> Dual a #

mconcat :: [Dual a] -> Dual a #

Monoid (Endo a) 
Instance details

Defined in Data.Semigroup.Internal

Methods

mempty :: Endo a #

mappend :: Endo a -> Endo a -> Endo a #

mconcat :: [Endo a] -> Endo a #

Num a => Monoid (Product a) 
Instance details

Defined in Data.Semigroup.Internal

Methods

mempty :: Product a #

mappend :: Product a -> Product a -> Product a #

mconcat :: [Product a] -> Product a #

Num a => Monoid (Sum a) 
Instance details

Defined in Data.Semigroup.Internal

Methods

mempty :: Sum a #

mappend :: Sum a -> Sum a -> Sum a #

mconcat :: [Sum a] -> Sum a #

Monoid a => Monoid (Down a) 
Instance details

Defined in Data.Ord

Methods

mempty :: Down a #

mappend :: Down a -> Down a -> Down a #

mconcat :: [Down a] -> Down a #

Monoid (First a) 
Instance details

Defined in Data.Monoid

Methods

mempty :: First a #

mappend :: First a -> First a -> First a #

mconcat :: [First a] -> First a #

Monoid (Last a) 
Instance details

Defined in Data.Monoid

Methods

mempty :: Last a #

mappend :: Last a -> Last a -> Last a #

mconcat :: [Last a] -> Last a #

(Ord a, Bounded a) => Monoid (Max a) 
Instance details

Defined in Data.Semigroup

Methods

mempty :: Max a #

mappend :: Max a -> Max a -> Max a #

mconcat :: [Max a] -> Max a #

(Ord a, Bounded a) => Monoid (Min a) 
Instance details

Defined in Data.Semigroup

Methods

mempty :: Min a #

mappend :: Min a -> Min a -> Min a #

mconcat :: [Min a] -> Min a #

Semigroup a => Monoid (Option a) 
Instance details

Defined in Data.Semigroup

Methods

mempty :: Option a #

mappend :: Option a -> Option a -> Option a #

mconcat :: [Option a] -> Option a #

Monoid m => Monoid (WrappedMonoid m) 
Instance details

Defined in Data.Semigroup

Methods

mempty :: WrappedMonoid m #

mappend :: WrappedMonoid m -> WrappedMonoid m -> WrappedMonoid m #

mconcat :: [WrappedMonoid m] -> WrappedMonoid m #

Monoid (InfoVal v) Source # 
Instance details

Defined in Propellor.Types.Info

Methods

mempty :: InfoVal v #

mappend :: InfoVal v -> InfoVal v -> InfoVal v #

mconcat :: [InfoVal v] -> InfoVal v #

Num a => Monoid (AlphaColour a) 
Instance details

Defined in Data.Colour.Internal

Methods

mempty :: AlphaColour a #

mappend :: AlphaColour a -> AlphaColour a -> AlphaColour a #

mconcat :: [AlphaColour a] -> AlphaColour a #

Num a => Monoid (Colour a) 
Instance details

Defined in Data.Colour.Internal

Methods

mempty :: Colour a #

mappend :: Colour a -> Colour a -> Colour a #

mconcat :: [Colour a] -> Colour a #

Monoid (Propellor Result) Source # 
Instance details

Defined in Propellor.Types.Core

Monoid (Doc a) 
Instance details

Defined in Text.PrettyPrint.Annotated.HughesPJ

Methods

mempty :: Doc a #

mappend :: Doc a -> Doc a -> Doc a #

mconcat :: [Doc a] -> Doc a #

(Semigroup a, Monoid a) => Monoid (Concurrently a) 
Instance details

Defined in Control.Concurrent.Async

Methods

mempty :: Concurrently a #

mappend :: Concurrently a -> Concurrently a -> Concurrently a #

mconcat :: [Concurrently a] -> Concurrently a #

Monoid (IntMap a) 
Instance details

Defined in Data.IntMap.Internal

Methods

mempty :: IntMap a #

mappend :: IntMap a -> IntMap a -> IntMap a #

mconcat :: [IntMap a] -> IntMap a #

Monoid (Seq a) 
Instance details

Defined in Data.Sequence.Internal

Methods

mempty :: Seq a #

mappend :: Seq a -> Seq a -> Seq a #

mconcat :: [Seq a] -> Seq a #

SingI metatypes => Monoid (Property (MetaTypes metatypes)) Source #

Any type of Property is a Monoid.

Instance details

Defined in Propellor.Types

Methods

mempty :: Property (MetaTypes metatypes) #

mappend :: Property (MetaTypes metatypes) -> Property (MetaTypes metatypes) -> Property (MetaTypes metatypes) #

mconcat :: [Property (MetaTypes metatypes)] -> Property (MetaTypes metatypes) #

Monoid b => Monoid (a -> b) 
Instance details

Defined in GHC.Base

Methods

mempty :: a -> b #

mappend :: (a -> b) -> (a -> b) -> a -> b #

mconcat :: [a -> b] -> a -> b #

Monoid (U1 p) 
Instance details

Defined in GHC.Generics

Methods

mempty :: U1 p #

mappend :: U1 p -> U1 p -> U1 p #

mconcat :: [U1 p] -> U1 p #

(Monoid a, Monoid b) => Monoid (a, b) 
Instance details

Defined in GHC.Base

Methods

mempty :: (a, b) #

mappend :: (a, b) -> (a, b) -> (a, b) #

mconcat :: [(a, b)] -> (a, b) #

Ord k => Monoid (Map k v) 
Instance details

Defined in Data.Map.Internal

Methods

mempty :: Map k v #

mappend :: Map k v -> Map k v -> Map k v #

mconcat :: [Map k v] -> Map k v #

Monoid (Proxy s) 
Instance details

Defined in Data.Proxy

Methods

mempty :: Proxy s #

mappend :: Proxy s -> Proxy s -> Proxy s #

mconcat :: [Proxy s] -> Proxy s #

(Monoid (Property (MetaTypes setupmetatypes)), Monoid (Property (MetaTypes undometatypes)), SingI setupmetatypes, SingI undometatypes) => Monoid (RevertableProperty (MetaTypes setupmetatypes) (MetaTypes undometatypes)) Source # 
Instance details

Defined in Propellor.Types

Methods

mempty :: RevertableProperty (MetaTypes setupmetatypes) (MetaTypes undometatypes) #

mappend :: RevertableProperty (MetaTypes setupmetatypes) (MetaTypes undometatypes) -> RevertableProperty (MetaTypes setupmetatypes) (MetaTypes undometatypes) -> RevertableProperty (MetaTypes setupmetatypes) (MetaTypes undometatypes) #

mconcat :: [RevertableProperty (MetaTypes setupmetatypes) (MetaTypes undometatypes)] -> RevertableProperty (MetaTypes setupmetatypes) (MetaTypes undometatypes) #

Monoid (f p) => Monoid (Rec1 f p) 
Instance details

Defined in GHC.Generics

Methods

mempty :: Rec1 f p #

mappend :: Rec1 f p -> Rec1 f p -> Rec1 f p #

mconcat :: [Rec1 f p] -> Rec1 f p #

(Monoid a, Monoid b, Monoid c) => Monoid (a, b, c) 
Instance details

Defined in GHC.Base

Methods

mempty :: (a, b, c) #

mappend :: (a, b, c) -> (a, b, c) -> (a, b, c) #

mconcat :: [(a, b, c)] -> (a, b, c) #

Monoid a => Monoid (Const a b) 
Instance details

Defined in Data.Functor.Const

Methods

mempty :: Const a b #

mappend :: Const a b -> Const a b -> Const a b #

mconcat :: [Const a b] -> Const a b #

Alternative f => Monoid (Alt f a) 
Instance details

Defined in Data.Semigroup.Internal

Methods

mempty :: Alt f a #

mappend :: Alt f a -> Alt f a -> Alt f a #

mconcat :: [Alt f a] -> Alt f a #

(Applicative f, Monoid a) => Monoid (Ap f a) 
Instance details

Defined in Data.Monoid

Methods

mempty :: Ap f a #

mappend :: Ap f a -> Ap f a -> Ap f a #

mconcat :: [Ap f a] -> Ap f a #

Monoid c => Monoid (K1 i c p) 
Instance details

Defined in GHC.Generics

Methods

mempty :: K1 i c p #

mappend :: K1 i c p -> K1 i c p -> K1 i c p #

mconcat :: [K1 i c p] -> K1 i c p #

(Monoid (f p), Monoid (g p)) => Monoid ((f :*: g) p) 
Instance details

Defined in GHC.Generics

Methods

mempty :: (f :*: g) p #

mappend :: (f :*: g) p -> (f :*: g) p -> (f :*: g) p #

mconcat :: [(f :*: g) p] -> (f :*: g) p #

(Monoid a, Monoid b, Monoid c, Monoid d) => Monoid (a, b, c, d) 
Instance details

Defined in GHC.Base

Methods

mempty :: (a, b, c, d) #

mappend :: (a, b, c, d) -> (a, b, c, d) -> (a, b, c, d) #

mconcat :: [(a, b, c, d)] -> (a, b, c, d) #

Monoid (f p) => Monoid (M1 i c f p) 
Instance details

Defined in GHC.Generics

Methods

mempty :: M1 i c f p #

mappend :: M1 i c f p -> M1 i c f p -> M1 i c f p #

mconcat :: [M1 i c f p] -> M1 i c f p #

Monoid (f (g p)) => Monoid ((f :.: g) p) 
Instance details

Defined in GHC.Generics

Methods

mempty :: (f :.: g) p #

mappend :: (f :.: g) p -> (f :.: g) p -> (f :.: g) p #

mconcat :: [(f :.: g) p] -> (f :.: g) p #

(Monoid a, Monoid b, Monoid c, Monoid d, Monoid e) => Monoid (a, b, c, d, e) 
Instance details

Defined in GHC.Base

Methods

mempty :: (a, b, c, d, e) #

mappend :: (a, b, c, d, e) -> (a, b, c, d, e) -> (a, b, c, d, e) #

mconcat :: [(a, b, c, d, e)] -> (a, b, c, d, e) #

newtype Any #

Constructors

Any 

Fields

Instances
Bounded Any 
Instance details

Defined in Data.Semigroup.Internal

Methods

minBound :: Any

maxBound :: Any

Eq Any 
Instance details

Defined in Data.Semigroup.Internal

Methods

(==) :: Any -> Any -> Bool

(/=) :: Any -> Any -> Bool

Ord Any 
Instance details

Defined in Data.Semigroup.Internal

Methods

compare :: Any -> Any -> Ordering

(<) :: Any -> Any -> Bool

(<=) :: Any -> Any -> Bool

(>) :: Any -> Any -> Bool

(>=) :: Any -> Any -> Bool

max :: Any -> Any -> Any

min :: Any -> Any -> Any

Read Any 
Instance details

Defined in Data.Semigroup.Internal

Methods

readsPrec :: Int -> ReadS Any

readList :: ReadS [Any]

readPrec :: ReadPrec Any

readListPrec :: ReadPrec [Any]

Show Any 
Instance details

Defined in Data.Semigroup.Internal

Methods

showsPrec :: Int -> Any -> ShowS

show :: Any -> String

showList :: [Any] -> ShowS

Generic Any 
Instance details

Defined in Data.Semigroup.Internal

Associated Types

type Rep Any :: Type -> Type

Methods

from :: Any -> Rep Any x

to :: Rep Any x -> Any

Semigroup Any 
Instance details

Defined in Data.Semigroup.Internal

Methods

(<>) :: Any -> Any -> Any #

sconcat :: NonEmpty Any -> Any

stimes :: Integral b => b -> Any -> Any

Monoid Any 
Instance details

Defined in Data.Semigroup.Internal

Methods

mempty :: Any #

mappend :: Any -> Any -> Any #

mconcat :: [Any] -> Any #

type Rep Any 
Instance details

Defined in Data.Semigroup.Internal

type Rep Any = D1 (MetaData "Any" "Data.Semigroup.Internal" "base" True) (C1 (MetaCons "Any" PrefixI True) (S1 (MetaSel (Just "getAny") NoSourceUnpackedness NoSourceStrictness DecidedLazy) (Rec0 Bool)))

newtype Dual a #

Constructors

Dual 

Fields

Instances
Monad Dual 
Instance details

Defined in Data.Semigroup.Internal

Methods

(>>=) :: Dual a -> (a -> Dual b) -> Dual b

(>>) :: Dual a -> Dual b -> Dual b

return :: a -> Dual a

fail :: String -> Dual a

Functor Dual 
Instance details

Defined in Data.Semigroup.Internal

Methods

fmap :: (a -> b) -> Dual a -> Dual b

(<$) :: a -> Dual b -> Dual a

MonadFix Dual 
Instance details

Defined in Control.Monad.Fix

Methods

mfix :: (a -> Dual a) -> Dual a

Applicative Dual 
Instance details

Defined in Data.Semigroup.Internal

Methods

pure :: a -> Dual a

(<*>) :: Dual (a -> b) -> Dual a -> Dual b

liftA2 :: (a -> b -> c) -> Dual a -> Dual b -> Dual c

(*>) :: Dual a -> Dual b -> Dual b

(<*) :: Dual a -> Dual b -> Dual a

Foldable Dual 
Instance details

Defined in Data.Foldable

Methods

fold :: Monoid m => Dual m -> m

foldMap :: Monoid m => (a -> m) -> Dual a -> m

foldr :: (a -> b -> b) -> b -> Dual a -> b

foldr' :: (a -> b -> b) -> b -> Dual a -> b

foldl :: (b -> a -> b) -> b -> Dual a -> b

foldl' :: (b -> a -> b) -> b -> Dual a -> b

foldr1 :: (a -> a -> a) -> Dual a -> a

foldl1 :: (a -> a -> a) -> Dual a -> a

toList :: Dual a -> [a]

null :: Dual a -> Bool

length :: Dual a -> Int

elem :: Eq a => a -> Dual a -> Bool

maximum :: Ord a => Dual a -> a

minimum :: Ord a => Dual a -> a

sum :: Num a => Dual a -> a

product :: Num a => Dual a -> a

Traversable Dual 
Instance details

Defined in Data.Traversable

Methods

traverse :: Applicative f => (a -> f b) -> Dual a -> f (Dual b)

sequenceA :: Applicative f => Dual (f a) -> f (Dual a)

mapM :: Monad m => (a -> m b) -> Dual a -> m (Dual b)

sequence :: Monad m => Dual (m a) -> m (Dual a)

Bounded a => Bounded (Dual a) 
Instance details

Defined in Data.Semigroup.Internal

Methods

minBound :: Dual a

maxBound :: Dual a

Eq a => Eq (Dual a) 
Instance details

Defined in Data.Semigroup.Internal

Methods

(==) :: Dual a -> Dual a -> Bool

(/=) :: Dual a -> Dual a -> Bool

Ord a => Ord (Dual a) 
Instance details

Defined in Data.Semigroup.Internal

Methods

compare :: Dual a -> Dual a -> Ordering

(<) :: Dual a -> Dual a -> Bool

(<=) :: Dual a -> Dual a -> Bool

(>) :: Dual a -> Dual a -> Bool

(>=) :: Dual a -> Dual a -> Bool

max :: Dual a -> Dual a -> Dual a

min :: Dual a -> Dual a -> Dual a

Read a => Read (Dual a) 
Instance details

Defined in Data.Semigroup.Internal

Methods

readsPrec :: Int -> ReadS (Dual a)

readList :: ReadS [Dual a]

readPrec :: ReadPrec (Dual a)

readListPrec :: ReadPrec [Dual a]

Show a => Show (Dual a) 
Instance details

Defined in Data.Semigroup.Internal

Methods

showsPrec :: Int -> Dual a -> ShowS

show :: Dual a -> String

showList :: [Dual a] -> ShowS

Generic (Dual a) 
Instance details

Defined in Data.Semigroup.Internal

Associated Types

type Rep (Dual a) :: Type -> Type

Methods

from :: Dual a -> Rep (Dual a) x

to :: Rep (Dual a) x -> Dual a

Semigroup a => Semigroup (Dual a) 
Instance details

Defined in Data.Semigroup.Internal

Methods

(<>) :: Dual a -> Dual a -> Dual a #

sconcat :: NonEmpty (Dual a) -> Dual a

stimes :: Integral b => b -> Dual a -> Dual a

Monoid a => Monoid (Dual a) 
Instance details

Defined in Data.Semigroup.Internal

Methods

mempty :: Dual a #

mappend :: Dual a -> Dual a -> Dual a #

mconcat :: [Dual a] -> Dual a #

Generic1 Dual 
Instance details

Defined in Data.Semigroup.Internal

Associated Types

type Rep1 Dual :: k -> Type

Methods

from1 :: Dual a -> Rep1 Dual a

to1 :: Rep1 Dual a -> Dual a

type Rep (Dual a) 
Instance details

Defined in Data.Semigroup.Internal

type Rep (Dual a) = D1 (MetaData "Dual" "Data.Semigroup.Internal" "base" True) (C1 (MetaCons "Dual" PrefixI True) (S1 (MetaSel (Just "getDual") NoSourceUnpackedness NoSourceStrictness DecidedLazy) (Rec0 a)))
type Rep1 Dual 
Instance details

Defined in Data.Semigroup.Internal

type Rep1 Dual = D1 (MetaData "Dual" "Data.Semigroup.Internal" "base" True) (C1 (MetaCons "Dual" PrefixI True) (S1 (MetaSel (Just "getDual") NoSourceUnpackedness NoSourceStrictness DecidedLazy) Par1))

newtype Endo a #

Constructors

Endo 

Fields

Instances
Generic (Endo a) 
Instance details

Defined in Data.Semigroup.Internal

Associated Types

type Rep (Endo a) :: Type -> Type

Methods

from :: Endo a -> Rep (Endo a) x

to :: Rep (Endo a) x -> Endo a

Semigroup (Endo a) 
Instance details

Defined in Data.Semigroup.Internal

Methods

(<>) :: Endo a -> Endo a -> Endo a #

sconcat :: NonEmpty (Endo a) -> Endo a

stimes :: Integral b => b -> Endo a -> Endo a

Monoid (Endo a) 
Instance details

Defined in Data.Semigroup.Internal

Methods

mempty :: Endo a #

mappend :: Endo a -> Endo a -> Endo a #

mconcat :: [Endo a] -> Endo a #

type Rep (Endo a) 
Instance details

Defined in Data.Semigroup.Internal

type Rep (Endo a) = D1 (MetaData "Endo" "Data.Semigroup.Internal" "base" True) (C1 (MetaCons "Endo" PrefixI True) (S1 (MetaSel (Just "appEndo") NoSourceUnpackedness NoSourceStrictness DecidedLazy) (Rec0 (a -> a))))

newtype Product a #

Constructors

Product 

Fields

Instances
Monad Product 
Instance details

Defined in Data.Semigroup.Internal

Methods

(>>=) :: Product a -> (a -> Product b) -> Product b

(>>) :: Product a -> Product b -> Product b

return :: a -> Product a

fail :: String -> Product a

Functor Product 
Instance details

Defined in Data.Semigroup.Internal

Methods

fmap :: (a -> b) -> Product a -> Product b

(<$) :: a -> Product b -> Product a

MonadFix Product 
Instance details

Defined in Control.Monad.Fix

Methods

mfix :: (a -> Product a) -> Product a

Applicative Product 
Instance details

Defined in Data.Semigroup.Internal

Methods

pure :: a -> Product a

(<*>) :: Product (a -> b) -> Product a -> Product b

liftA2 :: (a -> b -> c) -> Product a -> Product b -> Product c

(*>) :: Product a -> Product b -> Product b

(<*) :: Product a -> Product b -> Product a

Foldable Product 
Instance details

Defined in Data.Foldable

Methods

fold :: Monoid m => Product m -> m

foldMap :: Monoid m => (a -> m) -> Product a -> m

foldr :: (a -> b -> b) -> b -> Product a -> b

foldr' :: (a -> b -> b) -> b -> Product a -> b

foldl :: (b -> a -> b) -> b -> Product a -> b

foldl' :: (b -> a -> b) -> b -> Product a -> b

foldr1 :: (a -> a -> a) -> Product a -> a

foldl1 :: (a -> a -> a) -> Product a -> a

toList :: Product a -> [a]

null :: Product a -> Bool

length :: Product a -> Int

elem :: Eq a => a -> Product a -> Bool

maximum :: Ord a => Product a -> a

minimum :: Ord a => Product a -> a

sum :: Num a => Product a -> a

product :: Num a => Product a -> a

Traversable Product 
Instance details

Defined in Data.Traversable

Methods

traverse :: Applicative f => (a -> f b) -> Product a -> f (Product b)

sequenceA :: Applicative f => Product (f a) -> f (Product a)

mapM :: Monad m => (a -> m b) -> Product a -> m (Product b)

sequence :: Monad m => Product (m a) -> m (Product a)

Bounded a => Bounded (Product a) 
Instance details

Defined in Data.Semigroup.Internal

Eq a => Eq (Product a) 
Instance details

Defined in Data.Semigroup.Internal

Methods

(==) :: Product a -> Product a -> Bool

(/=) :: Product a -> Product a -> Bool

Num a => Num (Product a) 
Instance details

Defined in Data.Semigroup.Internal

Methods

(+) :: Product a -> Product a -> Product a

(-) :: Product a -> Product a -> Product a

(*) :: Product a -> Product a -> Product a

negate :: Product a -> Product a

abs :: Product a -> Product a

signum :: Product a -> Product a

fromInteger :: Integer -> Product a

Ord a => Ord (Product a) 
Instance details

Defined in Data.Semigroup.Internal

Methods

compare :: Product a -> Product a -> Ordering

(<) :: Product a -> Product a -> Bool

(<=) :: Product a -> Product a -> Bool

(>) :: Product a -> Product a -> Bool

(>=) :: Product a -> Product a -> Bool

max :: Product a -> Product a -> Product a

min :: Product a -> Product a -> Product a

Read a => Read (Product a) 
Instance details

Defined in Data.Semigroup.Internal

Methods

readsPrec :: Int -> ReadS (Product a)

readList :: ReadS [Product a]

readPrec :: ReadPrec (Product a)

readListPrec :: ReadPrec [Product a]

Show a => Show (Product a) 
Instance details

Defined in Data.Semigroup.Internal

Methods

showsPrec :: Int -> Product a -> ShowS

show :: Product a -> String

showList :: [Product a] -> ShowS

Generic (Product a) 
Instance details

Defined in Data.Semigroup.Internal

Associated Types

type Rep (Product a) :: Type -> Type

Methods

from :: Product a -> Rep (Product a) x

to :: Rep (Product a) x -> Product a

Num a => Semigroup (Product a) 
Instance details

Defined in Data.Semigroup.Internal

Methods

(<>) :: Product a -> Product a -> Product a #

sconcat :: NonEmpty (Product a) -> Product a

stimes :: Integral b => b -> Product a -> Product a

Num a => Monoid (Product a) 
Instance details

Defined in Data.Semigroup.Internal

Methods

mempty :: Product a #

mappend :: Product a -> Product a -> Product a #

mconcat :: [Product a] -> Product a #

Generic1 Product 
Instance details

Defined in Data.Semigroup.Internal

Associated Types

type Rep1 Product :: k -> Type

Methods

from1 :: Product a -> Rep1 Product a

to1 :: Rep1 Product a -> Product a

type Rep (Product a) 
Instance details

Defined in Data.Semigroup.Internal

type Rep (Product a) = D1 (MetaData "Product" "Data.Semigroup.Internal" "base" True) (C1 (MetaCons "Product" PrefixI True) (S1 (MetaSel (Just "getProduct") NoSourceUnpackedness NoSourceStrictness DecidedLazy) (Rec0 a)))
type Rep1 Product 
Instance details

Defined in Data.Semigroup.Internal

type Rep1 Product = D1 (MetaData "Product" "Data.Semigroup.Internal" "base" True) (C1 (MetaCons "Product" PrefixI True) (S1 (MetaSel (Just "getProduct") NoSourceUnpackedness NoSourceStrictness DecidedLazy) Par1))

newtype Sum a #

Constructors

Sum 

Fields

Instances
Monad Sum 
Instance details

Defined in Data.Semigroup.Internal

Methods

(>>=) :: Sum a -> (a -> Sum b) -> Sum b

(>>) :: Sum a -> Sum b -> Sum b

return :: a -> Sum a

fail :: String -> Sum a

Functor Sum 
Instance details

Defined in Data.Semigroup.Internal

Methods

fmap :: (a -> b) -> Sum a -> Sum b

(<$) :: a -> Sum b -> Sum a

MonadFix Sum 
Instance details

Defined in Control.Monad.Fix

Methods

mfix :: (a -> Sum a) -> Sum a

Applicative Sum 
Instance details

Defined in Data.Semigroup.Internal

Methods

pure :: a -> Sum a

(<*>) :: Sum (a -> b) -> Sum a -> Sum b

liftA2 :: (a -> b -> c) -> Sum a -> Sum b -> Sum c

(*>) :: Sum a -> Sum b -> Sum b

(<*) :: Sum a -> Sum b -> Sum a

Foldable Sum 
Instance details

Defined in Data.Foldable

Methods

fold :: Monoid m => Sum m -> m

foldMap :: Monoid m => (a -> m) -> Sum a -> m

foldr :: (a -> b -> b) -> b -> Sum a -> b

foldr' :: (a -> b -> b) -> b -> Sum a -> b

foldl :: (b -> a -> b) -> b -> Sum a -> b

foldl' :: (b -> a -> b) -> b -> Sum a -> b

foldr1 :: (a -> a -> a) -> Sum a -> a

foldl1 :: (a -> a -> a) -> Sum a -> a

toList :: Sum a -> [a]

null :: Sum a -> Bool

length :: Sum a -> Int

elem :: Eq a => a -> Sum a -> Bool

maximum :: Ord a => Sum a -> a

minimum :: Ord a => Sum a -> a

sum :: Num a => Sum a -> a

product :: Num a => Sum a -> a

Traversable Sum 
Instance details

Defined in Data.Traversable

Methods

traverse :: Applicative f => (a -> f b) -> Sum a -> f (Sum b)

sequenceA :: Applicative f => Sum (f a) -> f (Sum a)

mapM :: Monad m => (a -> m b) -> Sum a -> m (Sum b)

sequence :: Monad m => Sum (m a) -> m (Sum a)

Bounded a => Bounded (Sum a) 
Instance details

Defined in Data.Semigroup.Internal

Methods

minBound :: Sum a

maxBound :: Sum a

Eq a => Eq (Sum a) 
Instance details

Defined in Data.Semigroup.Internal

Methods

(==) :: Sum a -> Sum a -> Bool

(/=) :: Sum a -> Sum a -> Bool

Num a => Num (Sum a) 
Instance details

Defined in Data.Semigroup.Internal

Methods

(+) :: Sum a -> Sum a -> Sum a

(-) :: Sum a -> Sum a -> Sum a

(*) :: Sum a -> Sum a -> Sum a

negate :: Sum a -> Sum a

abs :: Sum a -> Sum a

signum :: Sum a -> Sum a

fromInteger :: Integer -> Sum a

Ord a => Ord (Sum a) 
Instance details

Defined in Data.Semigroup.Internal

Methods

compare :: Sum a -> Sum a -> Ordering

(<) :: Sum a -> Sum a -> Bool

(<=) :: Sum a -> Sum a -> Bool

(>) :: Sum a -> Sum a -> Bool

(>=) :: Sum a -> Sum a -> Bool

max :: Sum a -> Sum a -> Sum a

min :: Sum a -> Sum a -> Sum a

Read a => Read (Sum a) 
Instance details

Defined in Data.Semigroup.Internal

Methods

readsPrec :: Int -> ReadS (Sum a)

readList :: ReadS [Sum a]

readPrec :: ReadPrec (Sum a)

readListPrec :: ReadPrec [Sum a]

Show a => Show (Sum a) 
Instance details

Defined in Data.Semigroup.Internal

Methods

showsPrec :: Int -> Sum a -> ShowS

show :: Sum a -> String

showList :: [Sum a] -> ShowS

Generic (Sum a) 
Instance details

Defined in Data.Semigroup.Internal

Associated Types

type Rep (Sum a) :: Type -> Type

Methods

from :: Sum a -> Rep (Sum a) x

to :: Rep (Sum a) x -> Sum a

Num a => Semigroup (Sum a) 
Instance details

Defined in Data.Semigroup.Internal

Methods

(<>) :: Sum a -> Sum a -> Sum a #

sconcat :: NonEmpty (Sum a) -> Sum a

stimes :: Integral b => b -> Sum a -> Sum a

Num a => Monoid (Sum a) 
Instance details

Defined in Data.Semigroup.Internal

Methods

mempty :: Sum a #

mappend :: Sum a -> Sum a -> Sum a #

mconcat :: [Sum a] -> Sum a #

Generic1 Sum 
Instance details

Defined in Data.Semigroup.Internal

Associated Types

type Rep1 Sum :: k -> Type

Methods

from1 :: Sum a -> Rep1 Sum a

to1 :: Rep1 Sum a -> Sum a

type Rep (Sum a) 
Instance details

Defined in Data.Semigroup.Internal

type Rep (Sum a) = D1 (MetaData "Sum" "Data.Semigroup.Internal" "base" True) (C1 (MetaCons "Sum" PrefixI True) (S1 (MetaSel (Just "getSum") NoSourceUnpackedness NoSourceStrictness DecidedLazy) (Rec0 a)))
type Rep1 Sum 
Instance details

Defined in Data.Semigroup.Internal

type Rep1 Sum = D1 (MetaData "Sum" "Data.Semigroup.Internal" "base" True) (C1 (MetaCons "Sum" PrefixI True) (S1 (MetaSel (Just "getSum") NoSourceUnpackedness NoSourceStrictness DecidedLazy) Par1))

newtype All #

Constructors

All 

Fields

Instances
Bounded All 
Instance details

Defined in Data.Semigroup.Internal

Methods

minBound :: All

maxBound :: All

Eq All 
Instance details

Defined in Data.Semigroup.Internal

Methods

(==) :: All -> All -> Bool

(/=) :: All -> All -> Bool

Ord All 
Instance details

Defined in Data.Semigroup.Internal

Methods

compare :: All -> All -> Ordering

(<) :: All -> All -> Bool

(<=) :: All -> All -> Bool

(>) :: All -> All -> Bool

(>=) :: All -> All -> Bool

max :: All -> All -> All

min :: All -> All -> All

Read All 
Instance details

Defined in Data.Semigroup.Internal

Methods

readsPrec :: Int -> ReadS All

readList :: ReadS [All]

readPrec :: ReadPrec All

readListPrec :: ReadPrec [All]

Show All 
Instance details

Defined in Data.Semigroup.Internal

Methods

showsPrec :: Int -> All -> ShowS

show :: All -> String

showList :: [All] -> ShowS

Generic All 
Instance details

Defined in Data.Semigroup.Internal

Associated Types

type Rep All :: Type -> Type

Methods

from :: All -> Rep All x

to :: Rep All x -> All

Semigroup All 
Instance details

Defined in Data.Semigroup.Internal

Methods

(<>) :: All -> All -> All #

sconcat :: NonEmpty All -> All

stimes :: Integral b => b -> All -> All

Monoid All 
Instance details

Defined in Data.Semigroup.Internal

Methods

mempty :: All #

mappend :: All -> All -> All #

mconcat :: [All] -> All #

type Rep All 
Instance details

Defined in Data.Semigroup.Internal

type Rep All = D1 (MetaData "All" "Data.Semigroup.Internal" "base" True) (C1 (MetaCons "All" PrefixI True) (S1 (MetaSel (Just "getAll") NoSourceUnpackedness NoSourceStrictness DecidedLazy) (Rec0 Bool)))

newtype Alt (f :: k -> Type) (a :: k) :: forall k. (k -> Type) -> k -> Type #

Constructors

Alt 

Fields

Instances
Generic1 (Alt f :: k -> Type) 
Instance details

Defined in Data.Semigroup.Internal

Associated Types

type Rep1 (Alt f) :: k -> Type

Methods

from1 :: Alt f a -> Rep1 (Alt f) a

to1 :: Rep1 (Alt f) a -> Alt f a

Monad f => Monad (Alt f) 
Instance details

Defined in Data.Semigroup.Internal

Methods

(>>=) :: Alt f a -> (a -> Alt f b) -> Alt f b

(>>) :: Alt f a -> Alt f b -> Alt f b

return :: a -> Alt f a

fail :: String -> Alt f a

Functor f => Functor (Alt f) 
Instance details

Defined in Data.Semigroup.Internal

Methods

fmap :: (a -> b) -> Alt f a -> Alt f b

(<$) :: a -> Alt f b -> Alt f a

MonadFix f => MonadFix (Alt f) 
Instance details

Defined in Control.Monad.Fix

Methods

mfix :: (a -> Alt f a) -> Alt f a

Applicative f => Applicative (Alt f) 
Instance details

Defined in Data.Semigroup.Internal

Methods

pure :: a -> Alt f a

(<*>) :: Alt f (a -> b) -> Alt f a -> Alt f b

liftA2 :: (a -> b -> c) -> Alt f a -> Alt f b -> Alt f c

(*>) :: Alt f a -> Alt f b -> Alt f b

(<*) :: Alt f a -> Alt f b -> Alt f a

Foldable f => Foldable (Alt f) 
Instance details

Defined in Data.Foldable

Methods

fold :: Monoid m => Alt f m -> m

foldMap :: Monoid m => (a -> m) -> Alt f a -> m

foldr :: (a -> b -> b) -> b -> Alt f a -> b

foldr' :: (a -> b -> b) -> b -> Alt f a -> b

foldl :: (b -> a -> b) -> b -> Alt f a -> b

foldl' :: (b -> a -> b) -> b -> Alt f a -> b

foldr1 :: (a -> a -> a) -> Alt f a -> a

foldl1 :: (a -> a -> a) -> Alt f a -> a

toList :: Alt f a -> [a]

null :: Alt f a -> Bool

length :: Alt f a -> Int

elem :: Eq a => a -> Alt f a -> Bool

maximum :: Ord a => Alt f a -> a

minimum :: Ord a => Alt f a -> a

sum :: Num a => Alt f a -> a

product :: Num a => Alt f a -> a

Traversable f => Traversable (Alt f) 
Instance details

Defined in Data.Traversable

Methods

traverse :: Applicative f0 => (a -> f0 b) -> Alt f a -> f0 (Alt f b)

sequenceA :: Applicative f0 => Alt f (f0 a) -> f0 (Alt f a)

mapM :: Monad m => (a -> m b) -> Alt f a -> m (Alt f b)

sequence :: Monad m => Alt f (m a) -> m (Alt f a)

Alternative f => Alternative (Alt f) 
Instance details

Defined in Data.Semigroup.Internal

Methods

empty :: Alt f a

(<|>) :: Alt f a -> Alt f a -> Alt f a

some :: Alt f a -> Alt f [a]

many :: Alt f a -> Alt f [a]

MonadPlus f => MonadPlus (Alt f) 
Instance details

Defined in Data.Semigroup.Internal

Methods

mzero :: Alt f a

mplus :: Alt f a -> Alt f a -> Alt f a

Enum (f a) => Enum (Alt f a) 
Instance details

Defined in Data.Semigroup.Internal

Methods

succ :: Alt f a -> Alt f a

pred :: Alt f a -> Alt f a

toEnum :: Int -> Alt f a

fromEnum :: Alt f a -> Int

enumFrom :: Alt f a -> [Alt f a]

enumFromThen :: Alt f a -> Alt f a -> [Alt f a]

enumFromTo :: Alt f a -> Alt f a -> [Alt f a]

enumFromThenTo :: Alt f a -> Alt f a -> Alt f a -> [Alt f a]

Eq (f a) => Eq (Alt f a) 
Instance details

Defined in Data.Semigroup.Internal

Methods

(==) :: Alt f a -> Alt f a -> Bool

(/=) :: Alt f a -> Alt f a -> Bool

Num (f a) => Num (Alt f a) 
Instance details

Defined in Data.Semigroup.Internal

Methods

(+) :: Alt f a -> Alt f a -> Alt f a

(-) :: Alt f a -> Alt f a -> Alt f a

(*) :: Alt f a -> Alt f a -> Alt f a

negate :: Alt f a -> Alt f a

abs :: Alt f a -> Alt f a

signum :: Alt f a -> Alt f a

fromInteger :: Integer -> Alt f a

Ord (f a) => Ord (Alt f a) 
Instance details

Defined in Data.Semigroup.Internal

Methods

compare :: Alt f a -> Alt f a -> Ordering

(<) :: Alt f a -> Alt f a -> Bool

(<=) :: Alt f a -> Alt f a -> Bool

(>) :: Alt f a -> Alt f a -> Bool

(>=) :: Alt f a -> Alt f a -> Bool

max :: Alt f a -> Alt f a -> Alt f a

min :: Alt f a -> Alt f a -> Alt f a

Read (f a) => Read (Alt f a) 
Instance details

Defined in Data.Semigroup.Internal

Methods

readsPrec :: Int -> ReadS (Alt f a)

readList :: ReadS [Alt f a]

readPrec :: ReadPrec (Alt f a)

readListPrec :: ReadPrec [Alt f a]

Show (f a) => Show (Alt f a) 
Instance details

Defined in Data.Semigroup.Internal

Methods

showsPrec :: Int -> Alt f a -> ShowS

show :: Alt f a -> String

showList :: [Alt f a] -> ShowS

Generic (Alt f a) 
Instance details

Defined in Data.Semigroup.Internal

Associated Types

type Rep (Alt f a) :: Type -> Type

Methods

from :: Alt f a -> Rep (Alt f a) x

to :: Rep (Alt f a) x -> Alt f a

Alternative f => Semigroup (Alt f a) 
Instance details

Defined in Data.Semigroup.Internal

Methods

(<>) :: Alt f a -> Alt f a -> Alt f a #

sconcat :: NonEmpty (Alt f a) -> Alt f a

stimes :: Integral b => b -> Alt f a -> Alt f a

Alternative f => Monoid (Alt f a) 
Instance details

Defined in Data.Semigroup.Internal

Methods

mempty :: Alt f a #

mappend :: Alt f a -> Alt f a -> Alt f a #

mconcat :: [Alt f a] -> Alt f a #

type Rep1 (Alt f :: k -> Type) 
Instance details

Defined in Data.Semigroup.Internal

type Rep1 (Alt f :: k -> Type) = D1 (MetaData "Alt" "Data.Semigroup.Internal" "base" True) (C1 (MetaCons "Alt" PrefixI True) (S1 (MetaSel (Just "getAlt") NoSourceUnpackedness NoSourceStrictness DecidedLazy) (Rec1 f)))
type Rep (Alt f a) 
Instance details

Defined in Data.Semigroup.Internal

type Rep (Alt f a) = D1 (MetaData "Alt" "Data.Semigroup.Internal" "base" True) (C1 (MetaCons "Alt" PrefixI True) (S1 (MetaSel (Just "getAlt") NoSourceUnpackedness NoSourceStrictness DecidedLazy) (Rec0 (f a))))

newtype Ap (f :: k -> Type) (a :: k) :: forall k. (k -> Type) -> k -> Type #

Constructors

Ap 

Fields

Instances
Generic1 (Ap f :: k -> Type) 
Instance details

Defined in Data.Monoid

Associated Types

type Rep1 (Ap f) :: k -> Type

Methods

from1 :: Ap f a -> Rep1 (Ap f) a

to1 :: Rep1 (Ap f) a -> Ap f a

Monad f => Monad (Ap f) 
Instance details

Defined in Data.Monoid

Methods

(>>=) :: Ap f a -> (a -> Ap f b) -> Ap f b

(>>) :: Ap f a -> Ap f b -> Ap f b

return :: a -> Ap f a

fail :: String -> Ap f a

Functor f => Functor (Ap f) 
Instance details

Defined in Data.Monoid

Methods

fmap :: (a -> b) -> Ap f a -> Ap f b

(<$) :: a -> Ap f b -> Ap f a

MonadFix f => MonadFix (Ap f) 
Instance details

Defined in Control.Monad.Fix

Methods

mfix :: (a -> Ap f a) -> Ap f a

MonadFail f => MonadFail (Ap f) 
Instance details

Defined in Data.Monoid

Methods

fail :: String -> Ap f a

Applicative f => Applicative (Ap f) 
Instance details

Defined in Data.Monoid

Methods

pure :: a -> Ap f a

(<*>) :: Ap f (a -> b) -> Ap f a -> Ap f b

liftA2 :: (a -> b -> c) -> Ap f a -> Ap f b -> Ap f c

(*>) :: Ap f a -> Ap f b -> Ap f b

(<*) :: Ap f a -> Ap f b -> Ap f a

Foldable f => Foldable (Ap f) 
Instance details

Defined in Data.Foldable

Methods

fold :: Monoid m => Ap f m -> m

foldMap :: Monoid m => (a -> m) -> Ap f a -> m

foldr :: (a -> b -> b) -> b -> Ap f a -> b

foldr' :: (a -> b -> b) -> b -> Ap f a -> b

foldl :: (b -> a -> b) -> b -> Ap f a -> b

foldl' :: (b -> a -> b) -> b -> Ap f a -> b

foldr1 :: (a -> a -> a) -> Ap f a -> a

foldl1 :: (a -> a -> a) -> Ap f a -> a

toList :: Ap f a -> [a]

null :: Ap f a -> Bool

length :: Ap f a -> Int

elem :: Eq a => a -> Ap f a -> Bool

maximum :: Ord a => Ap f a -> a

minimum :: Ord a => Ap f a -> a

sum :: Num a => Ap f a -> a

product :: Num a => Ap f a -> a

Traversable f => Traversable (Ap f) 
Instance details

Defined in Data.Traversable

Methods

traverse :: Applicative f0 => (a -> f0 b) -> Ap f a -> f0 (Ap f b)

sequenceA :: Applicative f0 => Ap f (f0 a) -> f0 (Ap f a)

mapM :: Monad m => (a -> m b) -> Ap f a -> m (Ap f b)

sequence :: Monad m => Ap f (m a) -> m (Ap f a)

Alternative f => Alternative (Ap f) 
Instance details

Defined in Data.Monoid

Methods

empty :: Ap f a

(<|>) :: Ap f a -> Ap f a -> Ap f a

some :: Ap f a -> Ap f [a]

many :: Ap f a -> Ap f [a]

MonadPlus f => MonadPlus (Ap f) 
Instance details

Defined in Data.Monoid

Methods

mzero :: Ap f a

mplus :: Ap f a -> Ap f a -> Ap f a

(Applicative f, Bounded a) => Bounded (Ap f a) 
Instance details

Defined in Data.Monoid

Methods

minBound :: Ap f a

maxBound :: Ap f a

Enum (f a) => Enum (Ap f a) 
Instance details

Defined in Data.Monoid

Methods

succ :: Ap f a -> Ap f a

pred :: Ap f a -> Ap f a

toEnum :: Int -> Ap f a

fromEnum :: Ap f a -> Int

enumFrom :: Ap f a -> [Ap f a]

enumFromThen :: Ap f a -> Ap f a -> [Ap f a]

enumFromTo :: Ap f a -> Ap f a -> [Ap f a]

enumFromThenTo :: Ap f a -> Ap f a -> Ap f a -> [Ap f a]

Eq (f a) => Eq (Ap f a) 
Instance details

Defined in Data.Monoid

Methods

(==) :: Ap f a -> Ap f a -> Bool

(/=) :: Ap f a -> Ap f a -> Bool

(Applicative f, Num a) => Num (Ap f a) 
Instance details

Defined in Data.Monoid

Methods

(+) :: Ap f a -> Ap f a -> Ap f a

(-) :: Ap f a -> Ap f a -> Ap f a

(*) :: Ap f a -> Ap f a -> Ap f a

negate :: Ap f a -> Ap f a

abs :: Ap f a -> Ap f a

signum :: Ap f a -> Ap f a

fromInteger :: Integer -> Ap f a

Ord (f a) => Ord (Ap f a) 
Instance details

Defined in Data.Monoid

Methods

compare :: Ap f a -> Ap f a -> Ordering

(<) :: Ap f a -> Ap f a -> Bool

(<=) :: Ap f a -> Ap f a -> Bool

(>) :: Ap f a -> Ap f a -> Bool

(>=) :: Ap f a -> Ap f a -> Bool

max :: Ap f a -> Ap f a -> Ap f a

min :: Ap f a -> Ap f a -> Ap f a

Read (f a) => Read (Ap f a) 
Instance details

Defined in Data.Monoid

Methods

readsPrec :: Int -> ReadS (Ap f a)

readList :: ReadS [Ap f a]

readPrec :: ReadPrec (Ap f a)

readListPrec :: ReadPrec [Ap f a]

Show (f a) => Show (Ap f a) 
Instance details

Defined in Data.Monoid

Methods

showsPrec :: Int -> Ap f a -> ShowS

show :: Ap f a -> String

showList :: [Ap f a] -> ShowS

Generic (Ap f a) 
Instance details

Defined in Data.Monoid

Associated Types

type Rep (Ap f a) :: Type -> Type

Methods

from :: Ap f a -> Rep (Ap f a) x

to :: Rep (Ap f a) x -> Ap f a

(Applicative f, Semigroup a) => Semigroup (Ap f a) 
Instance details

Defined in Data.Monoid

Methods

(<>) :: Ap f a -> Ap f a -> Ap f a #

sconcat :: NonEmpty (Ap f a) -> Ap f a

stimes :: Integral b => b -> Ap f a -> Ap f a

(Applicative f, Monoid a) => Monoid (Ap f a) 
Instance details

Defined in Data.Monoid

Methods

mempty :: Ap f a #

mappend :: Ap f a -> Ap f a -> Ap f a #

mconcat :: [Ap f a] -> Ap f a #

type Rep1 (Ap f :: k -> Type) 
Instance details

Defined in Data.Monoid

type Rep1 (Ap f :: k -> Type) = D1 (MetaData "Ap" "Data.Monoid" "base" True) (C1 (MetaCons "Ap" PrefixI True) (S1 (MetaSel (Just "getAp") NoSourceUnpackedness NoSourceStrictness DecidedLazy) (Rec1 f)))
type Rep (Ap f a) 
Instance details

Defined in Data.Monoid

type Rep (Ap f a) = D1 (MetaData "Ap" "Data.Monoid" "base" True) (C1 (MetaCons "Ap" PrefixI True) (S1 (MetaSel (Just "getAp") NoSourceUnpackedness NoSourceStrictness DecidedLazy) (Rec0 (f a))))

newtype First a #

Constructors

First 

Fields

Instances
Monad First 
Instance details

Defined in Data.Monoid

Methods

(>>=) :: First a -> (a -> First b) -> First b

(>>) :: First a -> First b -> First b

return :: a -> First a

fail :: String -> First a

Functor First 
Instance details

Defined in Data.Monoid

Methods

fmap :: (a -> b) -> First a -> First b

(<$) :: a -> First b -> First a

MonadFix First 
Instance details

Defined in Control.Monad.Fix

Methods

mfix :: (a -> First a) -> First a

Applicative First 
Instance details

Defined in Data.Monoid

Methods

pure :: a -> First a

(<*>) :: First (a -> b) -> First a -> First b

liftA2 :: (a -> b -> c) -> First a -> First b -> First c

(*>) :: First a -> First b -> First b

(<*) :: First a -> First b -> First a

Foldable First 
Instance details

Defined in Data.Foldable

Methods

fold :: Monoid m => First m -> m

foldMap :: Monoid m => (a -> m) -> First a -> m

foldr :: (a -> b -> b) -> b -> First a -> b

foldr' :: (a -> b -> b) -> b -> First a -> b

foldl :: (b -> a -> b) -> b -> First a -> b

foldl' :: (b -> a -> b) -> b -> First a -> b

foldr1 :: (a -> a -> a) -> First a -> a

foldl1 :: (a -> a -> a) -> First a -> a

toList :: First a -> [a]

null :: First a -> Bool

length :: First a -> Int

elem :: Eq a => a -> First a -> Bool

maximum :: Ord a => First a -> a

minimum :: Ord a => First a -> a

sum :: Num a => First a -> a

product :: Num a => First a -> a

Traversable First 
Instance details

Defined in Data.Traversable

Methods

traverse :: Applicative f => (a -> f b) -> First a -> f (First b)

sequenceA :: Applicative f => First (f a) -> f (First a)

mapM :: Monad m => (a -> m b) -> First a -> m (First b)

sequence :: Monad m => First (m a) -> m (First a)

Eq a => Eq (First a) 
Instance details

Defined in Data.Monoid

Methods

(==) :: First a -> First a -> Bool

(/=) :: First a -> First a -> Bool

Ord a => Ord (First a) 
Instance details

Defined in Data.Monoid

Methods

compare :: First a -> First a -> Ordering

(<) :: First a -> First a -> Bool

(<=) :: First a -> First a -> Bool

(>) :: First a -> First a -> Bool

(>=) :: First a -> First a -> Bool

max :: First a -> First a -> First a

min :: First a -> First a -> First a

Read a => Read (First a) 
Instance details

Defined in Data.Monoid

Methods

readsPrec :: Int -> ReadS (First a)

readList :: ReadS [First a]

readPrec :: ReadPrec (First a)

readListPrec :: ReadPrec [First a]

Show a => Show (First a) 
Instance details

Defined in Data.Monoid

Methods

showsPrec :: Int -> First a -> ShowS

show :: First a -> String

showList :: [First a] -> ShowS

Generic (First a) 
Instance details

Defined in Data.Monoid

Associated Types

type Rep (First a) :: Type -> Type

Methods

from :: First a -> Rep (First a) x

to :: Rep (First a) x -> First a

Semigroup (First a) 
Instance details

Defined in Data.Monoid

Methods

(<>) :: First a -> First a -> First a #

sconcat :: NonEmpty (First a) -> First a

stimes :: Integral b => b -> First a -> First a

Monoid (First a) 
Instance details

Defined in Data.Monoid

Methods

mempty :: First a #

mappend :: First a -> First a -> First a #

mconcat :: [First a] -> First a #

Generic1 First 
Instance details

Defined in Data.Monoid

Associated Types

type Rep1 First :: k -> Type

Methods

from1 :: First a -> Rep1 First a

to1 :: Rep1 First a -> First a

type Rep (First a) 
Instance details

Defined in Data.Monoid

type Rep (First a) = D1 (MetaData "First" "Data.Monoid" "base" True) (C1 (MetaCons "First" PrefixI True) (S1 (MetaSel (Just "getFirst") NoSourceUnpackedness NoSourceStrictness DecidedLazy) (Rec0 (Maybe a))))
type Rep1 First 
Instance details

Defined in Data.Monoid

type Rep1 First = D1 (MetaData "First" "Data.Monoid" "base" True) (C1 (MetaCons "First" PrefixI True) (S1 (MetaSel (Just "getFirst") NoSourceUnpackedness NoSourceStrictness DecidedLazy) (Rec1 Maybe)))

newtype Last a #

Constructors

Last 

Fields

Instances
Monad Last 
Instance details

Defined in Data.Monoid

Methods

(>>=) :: Last a -> (a -> Last b) -> Last b

(>>) :: Last a -> Last b -> Last b

return :: a -> Last a

fail :: String -> Last a

Functor Last 
Instance details

Defined in Data.Monoid

Methods

fmap :: (a -> b) -> Last a -> Last b

(<$) :: a -> Last b -> Last a

MonadFix Last 
Instance details

Defined in Control.Monad.Fix

Methods

mfix :: (a -> Last a) -> Last a

Applicative Last 
Instance details

Defined in Data.Monoid

Methods

pure :: a -> Last a

(<*>) :: Last (a -> b) -> Last a -> Last b

liftA2 :: (a -> b -> c) -> Last a -> Last b -> Last c

(*>) :: Last a -> Last b -> Last b

(<*) :: Last a -> Last b -> Last a

Foldable Last 
Instance details

Defined in Data.Foldable

Methods

fold :: Monoid m => Last m -> m

foldMap :: Monoid m => (a -> m) -> Last a -> m

foldr :: (a -> b -> b) -> b -> Last a -> b

foldr' :: (a -> b -> b) -> b -> Last a -> b

foldl :: (b -> a -> b) -> b -> Last a -> b

foldl' :: (b -> a -> b) -> b -> Last a -> b

foldr1 :: (a -> a -> a) -> Last a -> a

foldl1 :: (a -> a -> a) -> Last a -> a

toList :: Last a -> [a]

null :: Last a -> Bool

length :: Last a -> Int

elem :: Eq a => a -> Last a -> Bool

maximum :: Ord a => Last a -> a

minimum :: Ord a => Last a -> a

sum :: Num a => Last a -> a

product :: Num a => Last a -> a

Traversable Last 
Instance details

Defined in Data.Traversable

Methods

traverse :: Applicative f => (a -> f b) -> Last a -> f (Last b)

sequenceA :: Applicative f => Last (f a) -> f (Last a)

mapM :: Monad m => (a -> m b) -> Last a -> m (Last b)

sequence :: Monad m => Last (m a) -> m (Last a)

Eq a => Eq (Last a) 
Instance details

Defined in Data.Monoid

Methods

(==) :: Last a -> Last a -> Bool

(/=) :: Last a -> Last a -> Bool

Ord a => Ord (Last a) 
Instance details

Defined in Data.Monoid

Methods

compare :: Last a -> Last a -> Ordering

(<) :: Last a -> Last a -> Bool

(<=) :: Last a -> Last a -> Bool

(>) :: Last a -> Last a -> Bool

(>=) :: Last a -> Last a -> Bool

max :: Last a -> Last a -> Last a

min :: Last a -> Last a -> Last a

Read a => Read (Last a) 
Instance details

Defined in Data.Monoid

Methods

readsPrec :: Int -> ReadS (Last a)

readList :: ReadS [Last a]

readPrec :: ReadPrec (Last a)

readListPrec :: ReadPrec [Last a]

Show a => Show (Last a) 
Instance details

Defined in Data.Monoid

Methods

showsPrec :: Int -> Last a -> ShowS

show :: Last a -> String

showList :: [Last a] -> ShowS

Generic (Last a) 
Instance details

Defined in Data.Monoid

Associated Types

type Rep (Last a) :: Type -> Type

Methods

from :: Last a -> Rep (Last a) x

to :: Rep (Last a) x -> Last a

Semigroup (Last a) 
Instance details

Defined in Data.Monoid

Methods

(<>) :: Last a -> Last a -> Last a #

sconcat :: NonEmpty (Last a) -> Last a

stimes :: Integral b => b -> Last a -> Last a

Monoid (Last a) 
Instance details

Defined in Data.Monoid

Methods

mempty :: Last a #

mappend :: Last a -> Last a -> Last a #

mconcat :: [Last a] -> Last a #

Generic1 Last 
Instance details

Defined in Data.Monoid

Associated Types

type Rep1 Last :: k -> Type

Methods

from1 :: Last a -> Rep1 Last a

to1 :: Rep1 Last a -> Last a

type Rep (Last a) 
Instance details

Defined in Data.Monoid

type Rep (Last a) = D1 (MetaData "Last" "Data.Monoid" "base" True) (C1 (MetaCons "Last" PrefixI True) (S1 (MetaSel (Just "getLast") NoSourceUnpackedness NoSourceStrictness DecidedLazy) (Rec0 (Maybe a))))
type Rep1 Last 
Instance details

Defined in Data.Monoid

type Rep1 Last = D1 (MetaData "Last" "Data.Monoid" "base" True) (C1 (MetaCons "Last" PrefixI True) (S1 (MetaSel (Just "getLast") NoSourceUnpackedness NoSourceStrictness DecidedLazy) (Rec1 Maybe)))