Network.Tox.DHT.Distance
newtype Distance Source #
Constructors
Defined in Network.Tox.DHT.Distance
Methods
(==) :: Distance -> Distance -> Bool #
(/=) :: Distance -> Distance -> Bool #
compare :: Distance -> Distance -> Ordering #
(<) :: Distance -> Distance -> Bool #
(<=) :: Distance -> Distance -> Bool #
(>) :: Distance -> Distance -> Bool #
(>=) :: Distance -> Distance -> Bool #
max :: Distance -> Distance -> Distance #
min :: Distance -> Distance -> Distance #
readsPrec :: Int -> ReadS Distance #
readList :: ReadS [Distance] #
readPrec :: ReadPrec Distance #
readListPrec :: ReadPrec [Distance] #
showsPrec :: Int -> Distance -> ShowS #
show :: Distance -> String #
showList :: [Distance] -> ShowS #
(<>) :: Distance -> Distance -> Distance #
sconcat :: NonEmpty Distance -> Distance #
stimes :: Integral b => b -> Distance -> Distance #
mempty :: Distance #
mappend :: Distance -> Distance -> Distance #
mconcat :: [Distance] -> Distance #
arbitrary :: Gen Distance #
shrink :: Distance -> [Distance] #
log2 :: Distance -> Maybe Int Source #
xorDistance :: PublicKey -> PublicKey -> Distance Source #
rebaseDistance :: PublicKey -> PublicKey -> Distance -> Distance Source #
rebaseDistance a b (xorDistance a c) == xorDistance b c