stratux-types-0.0.11: A library for reading JSON output from stratux

Safe HaskellNone
LanguageHaskell2010

Data.Aviation.Stratux.Types.IcaoAddr

Documentation

data IcaoAddr Source #

Instances
Eq IcaoAddr Source # 
Instance details

Defined in Data.Aviation.Stratux.Types.IcaoAddr

Ord IcaoAddr Source # 
Instance details

Defined in Data.Aviation.Stratux.Types.IcaoAddr

Show IcaoAddr Source # 
Instance details

Defined in Data.Aviation.Stratux.Types.IcaoAddr

ToJSON IcaoAddr Source #
>>> encode (IcaoAddr 1 2 3)
"66051"
>>> encode (IcaoAddr 124 106 226)
"8153826"
Instance details

Defined in Data.Aviation.Stratux.Types.IcaoAddr

FromJSON IcaoAddr Source #
>>> decode "8153826" :: Maybe IcaoAddr
Just (IcaoAddr {_icaoAddrWord0 = 124, _icaoAddrWord1 = 106, _icaoAddrWord2 = 226})
>>> decode "66051" :: Maybe IcaoAddr
Just (IcaoAddr {_icaoAddrWord0 = 1, _icaoAddrWord1 = 2, _icaoAddrWord2 = 3})
Instance details

Defined in Data.Aviation.Stratux.Types.IcaoAddr

HasWord8s IcaoAddr Source #
>>> word8s %~ (+1) $ IcaoAddr 124 106 226
IcaoAddr {_icaoAddrWord0 = 125, _icaoAddrWord1 = 107, _icaoAddrWord2 = 227}
>>> word8s %~ (+1) $ IcaoAddr 1 2 3
IcaoAddr {_icaoAddrWord0 = 2, _icaoAddrWord1 = 3, _icaoAddrWord2 = 4}
Instance details

Defined in Data.Aviation.Stratux.Types.IcaoAddr

HasIcaoAddr IcaoAddr Source # 
Instance details

Defined in Data.Aviation.Stratux.Types.IcaoAddr