Java representation in Haskell