summaryrefslogtreecommitdiff
path: root/haskell/src/SpaceTraders/Model/Inventory.hs
blob: db74ddb70fa8fc4f95af1d07fda6cedf69dccb87 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
{-# LANGUAGE DeriveAnyClass #-}
{-# LANGUAGE DeriveGeneric #-}
{-# LANGUAGE OverloadedStrings #-}

module SpaceTraders.Model.Inventory
  ( Inventory(..)
  ) where

import Data.Aeson
import GHC.Generics
import qualified Data.Text as T

data Inventory = Inventory { description :: T.Text
                           , name :: T.Text
                           , symbol :: T.Text
                           , units :: Int
                           } deriving (FromJSON, Generic, Show, ToJSON)