ouroboros-network-api
Safe HaskellNone
LanguageHaskell2010

Ouroboros.Network.Point

Documentation

data WithOrigin t #

Constructors

Origin 
At !t 

Instances

Instances details
Functor WithOrigin 
Instance details

Defined in Cardano.Slotting.Slot

Methods

fmap :: (a -> b) -> WithOrigin a -> WithOrigin b #

(<$) :: a -> WithOrigin b -> WithOrigin a #

Foldable WithOrigin 
Instance details

Defined in Cardano.Slotting.Slot

Methods

fold :: Monoid m => WithOrigin m -> m #

foldMap :: Monoid m => (a -> m) -> WithOrigin a -> m #

foldMap' :: Monoid m => (a -> m) -> WithOrigin a -> m #

foldr :: (a -> b -> b) -> b -> WithOrigin a -> b #

foldr' :: (a -> b -> b) -> b -> WithOrigin a -> b #

foldl :: (b -> a -> b) -> b -> WithOrigin a -> b #

foldl' :: (b -> a -> b) -> b -> WithOrigin a -> b #

foldr1 :: (a -> a -> a) -> WithOrigin a -> a #

foldl1 :: (a -> a -> a) -> WithOrigin a -> a #

toList :: WithOrigin a -> [a] #

null :: WithOrigin a -> Bool #

length :: WithOrigin a -> Int #

elem :: Eq a => a -> WithOrigin a -> Bool #

maximum :: Ord a => WithOrigin a -> a #

minimum :: Ord a => WithOrigin a -> a #

sum :: Num a => WithOrigin a -> a #

product :: Num a => WithOrigin a -> a #

Traversable WithOrigin 
Instance details

Defined in Cardano.Slotting.Slot

Methods

traverse :: Applicative f => (a -> f b) -> WithOrigin a -> f (WithOrigin b) #

sequenceA :: Applicative f => WithOrigin (f a) -> f (WithOrigin a) #

mapM :: Monad m => (a -> m b) -> WithOrigin a -> m (WithOrigin b) #

sequence :: Monad m => WithOrigin (m a) -> m (WithOrigin a) #

FromJSON a => FromJSON (WithOrigin a) 
Instance details

Defined in Cardano.Slotting.Slot

ToJSON a => ToJSON (WithOrigin a) 
Instance details

Defined in Cardano.Slotting.Slot

(Serialise t, Typeable t) => FromCBOR (WithOrigin t) 
Instance details

Defined in Cardano.Slotting.Slot

(Serialise t, Typeable t) => ToCBOR (WithOrigin t) 
Instance details

Defined in Cardano.Slotting.Slot

Methods

toCBOR :: WithOrigin t -> Encoding #

encodedSizeExpr :: (forall t0. ToCBOR t0 => Proxy t0 -> Size) -> Proxy (WithOrigin t) -> Size #

encodedListSizeExpr :: (forall t0. ToCBOR t0 => Proxy t0 -> Size) -> Proxy [WithOrigin t] -> Size #

NFData a => NFData (WithOrigin a) 
Instance details

Defined in Cardano.Slotting.Slot

Methods

rnf :: WithOrigin a -> () #

Bounded t => Bounded (WithOrigin t) 
Instance details

Defined in Cardano.Slotting.Slot

Generic (WithOrigin t) 
Instance details

Defined in Cardano.Slotting.Slot

Associated Types

type Rep (WithOrigin t) 
Instance details

Defined in Cardano.Slotting.Slot

type Rep (WithOrigin t) = D1 ('MetaData "WithOrigin" "Cardano.Slotting.Slot" "cardano-slotting-0.2.0.0-9f9c1d3cf583b4a5a1b94ca6c7aa97d6161ffaa37cd2811c55245f3ba83bfbe2" 'False) (C1 ('MetaCons "Origin" 'PrefixI 'False) (U1 :: Type -> Type) :+: C1 ('MetaCons "At" 'PrefixI 'False) (S1 ('MetaSel ('Nothing :: Maybe Symbol) 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 t)))

Methods

from :: WithOrigin t -> Rep (WithOrigin t) x #

to :: Rep (WithOrigin t) x -> WithOrigin t #

Show t => Show (WithOrigin t) 
Instance details

Defined in Cardano.Slotting.Slot

Eq t => Eq (WithOrigin t) 
Instance details

Defined in Cardano.Slotting.Slot

Methods

(==) :: WithOrigin t -> WithOrigin t -> Bool #

(/=) :: WithOrigin t -> WithOrigin t -> Bool #

Ord t => Ord (WithOrigin t) 
Instance details

Defined in Cardano.Slotting.Slot

NoThunks t => NoThunks (WithOrigin t) 
Instance details

Defined in Cardano.Slotting.Slot

Serialise t => Serialise (WithOrigin t) 
Instance details

Defined in Cardano.Slotting.Slot

HasHeader block => Anchorable (WithOrigin SlotNo) (Anchor block) block Source # 
Instance details

Defined in Ouroboros.Network.AnchoredFragment

Methods

asAnchor :: block -> Anchor block Source #

getAnchorMeasure :: Proxy block -> Anchor block -> WithOrigin SlotNo Source #

type Rep (WithOrigin t) 
Instance details

Defined in Cardano.Slotting.Slot

type Rep (WithOrigin t) = D1 ('MetaData "WithOrigin" "Cardano.Slotting.Slot" "cardano-slotting-0.2.0.0-9f9c1d3cf583b4a5a1b94ca6c7aa97d6161ffaa37cd2811c55245f3ba83bfbe2" 'False) (C1 ('MetaCons "Origin" 'PrefixI 'False) (U1 :: Type -> Type) :+: C1 ('MetaCons "At" 'PrefixI 'False) (S1 ('MetaSel ('Nothing :: Maybe Symbol) 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 t)))

data Block slot hash Source #

Constructors

Block 

Fields

Instances

Instances details
Generic (Block slot hash) Source # 
Instance details

Defined in Ouroboros.Network.Point

Associated Types

type Rep (Block slot hash) 
Instance details

Defined in Ouroboros.Network.Point

type Rep (Block slot hash) = D1 ('MetaData "Block" "Ouroboros.Network.Point" "ouroboros-network-api-0.11.0.0-inplace" 'False) (C1 ('MetaCons "Block" 'PrefixI 'True) (S1 ('MetaSel ('Just "blockPointSlot") 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 slot) :*: S1 ('MetaSel ('Just "blockPointHash") 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 hash)))

Methods

from :: Block slot hash -> Rep (Block slot hash) x #

to :: Rep (Block slot hash) x -> Block slot hash #

(Show slot, Show hash) => Show (Block slot hash) Source # 
Instance details

Defined in Ouroboros.Network.Point

Methods

showsPrec :: Int -> Block slot hash -> ShowS #

show :: Block slot hash -> String #

showList :: [Block slot hash] -> ShowS #

(Eq slot, Eq hash) => Eq (Block slot hash) Source # 
Instance details

Defined in Ouroboros.Network.Point

Methods

(==) :: Block slot hash -> Block slot hash -> Bool #

(/=) :: Block slot hash -> Block slot hash -> Bool #

(Ord slot, Ord hash) => Ord (Block slot hash) Source # 
Instance details

Defined in Ouroboros.Network.Point

Methods

compare :: Block slot hash -> Block slot hash -> Ordering #

(<) :: Block slot hash -> Block slot hash -> Bool #

(<=) :: Block slot hash -> Block slot hash -> Bool #

(>) :: Block slot hash -> Block slot hash -> Bool #

(>=) :: Block slot hash -> Block slot hash -> Bool #

max :: Block slot hash -> Block slot hash -> Block slot hash #

min :: Block slot hash -> Block slot hash -> Block slot hash #

(NoThunks slot, NoThunks hash) => NoThunks (Block slot hash) Source # 
Instance details

Defined in Ouroboros.Network.Point

Methods

noThunks :: Context -> Block slot hash -> IO (Maybe ThunkInfo) #

wNoThunks :: Context -> Block slot hash -> IO (Maybe ThunkInfo) #

showTypeOf :: Proxy (Block slot hash) -> String #

type Rep (Block slot hash) Source # 
Instance details

Defined in Ouroboros.Network.Point

type Rep (Block slot hash) = D1 ('MetaData "Block" "Ouroboros.Network.Point" "ouroboros-network-api-0.11.0.0-inplace" 'False) (C1 ('MetaCons "Block" 'PrefixI 'True) (S1 ('MetaSel ('Just "blockPointSlot") 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 slot) :*: S1 ('MetaSel ('Just "blockPointHash") 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 hash)))

at :: t -> WithOrigin t #

block :: slot -> hash -> WithOrigin (Block slot hash) Source #

fromWithOrigin :: t -> WithOrigin t -> t #

withOrigin :: b -> (t -> b) -> WithOrigin t -> b #