language-java-0.2.8: Manipulating Java source: abstract syntax, lexer, parser, and pretty-printer

Safe HaskellSafe
LanguageHaskell98

Language.Java.Pretty

Documentation

prettyPrint :: Pretty a => a -> String #

parenPrec :: Int -> Int -> Doc -> Doc #

class Pretty a where #

Methods

pretty :: a -> Doc #

prettyPrec :: Int -> a -> Doc #

Instances

Pretty Name # 

Methods

pretty :: Name -> Doc #

prettyPrec :: Int -> Name -> Doc #

Pretty Ident # 

Methods

pretty :: Ident -> Doc #

prettyPrec :: Int -> Ident -> Doc #

Pretty TypeParam # 
Pretty PrimType # 

Methods

pretty :: PrimType -> Doc #

prettyPrec :: Int -> PrimType -> Doc #

Pretty WildcardBound # 
Pretty TypeArgument # 
Pretty ClassType # 
Pretty RefType # 

Methods

pretty :: RefType -> Doc #

prettyPrec :: Int -> RefType -> Doc #

Pretty Type # 

Methods

pretty :: Type -> Doc #

prettyPrec :: Int -> Type -> Doc #

Pretty ArrayInit # 
Pretty MethodInvocation # 
Pretty FieldAccess # 
Pretty ArrayIndex # 
Pretty Lhs # 

Methods

pretty :: Lhs -> Doc #

prettyPrec :: Int -> Lhs -> Doc #

Pretty AssignOp # 

Methods

pretty :: AssignOp -> Doc #

prettyPrec :: Int -> AssignOp -> Doc #

Pretty Op # 

Methods

pretty :: Op -> Doc #

prettyPrec :: Int -> Op -> Doc #

Pretty Literal # 

Methods

pretty :: Literal -> Doc #

prettyPrec :: Int -> Literal -> Doc #

Pretty Exp # 

Methods

pretty :: Exp -> Doc #

prettyPrec :: Int -> Exp -> Doc #

Pretty ForInit # 

Methods

pretty :: ForInit -> Doc #

prettyPrec :: Int -> ForInit -> Doc #

Pretty SwitchLabel # 
Pretty SwitchBlock # 
Pretty Catch # 

Methods

pretty :: Catch -> Doc #

prettyPrec :: Int -> Catch -> Doc #

Pretty Stmt # 

Methods

pretty :: Stmt -> Doc #

prettyPrec :: Int -> Stmt -> Doc #

Pretty BlockStmt # 
Pretty Block # 

Methods

pretty :: Block -> Doc #

prettyPrec :: Int -> Block -> Doc #

Pretty ElementValue # 
Pretty Annotation # 
Pretty Modifier # 

Methods

pretty :: Modifier -> Doc #

prettyPrec :: Int -> Modifier -> Doc #

Pretty ExplConstrInv # 
Pretty ConstructorBody # 
Pretty MethodBody # 
Pretty FormalParam # 
Pretty VarInit # 

Methods

pretty :: VarInit -> Doc #

prettyPrec :: Int -> VarInit -> Doc #

Pretty VarDeclId # 
Pretty VarDecl # 

Methods

pretty :: VarDecl -> Doc #

prettyPrec :: Int -> VarDecl -> Doc #

Pretty MemberDecl # 
Pretty Decl # 

Methods

pretty :: Decl -> Doc #

prettyPrec :: Int -> Decl -> Doc #

Pretty InterfaceBody # 
Pretty InterfaceDecl # 
Pretty EnumConstant # 
Pretty EnumBody # 

Methods

pretty :: EnumBody -> Doc #

prettyPrec :: Int -> EnumBody -> Doc #

Pretty ClassBody # 
Pretty ClassDecl # 
Pretty TypeDecl # 

Methods

pretty :: TypeDecl -> Doc #

prettyPrec :: Int -> TypeDecl -> Doc #

Pretty ImportDecl # 
Pretty PackageDecl # 
Pretty CompilationUnit # 

ppEVList :: (Pretty a, Pretty a1) => Int -> [(a1, a)] -> Doc #

ppArgs :: Pretty a => Int -> [a] -> Doc #

ppTypeParams :: Pretty a => Int -> [a] -> Doc #

maybePP :: Pretty a => Int -> Maybe a -> Doc #

opt :: Bool -> Doc -> Doc #

opPrec :: Num t => Op -> t #