接口的使用
com.sun.source.tree.BlockTree
使用 BlockTree 的包
-
BlockTree 在 com.sun.source.tree 中的用法
com.sun.source.tree 中返回 BlockTree 的方法修饰符和类型方法描述CatchTree.getBlock()返回捕获块。SynchronizedTree.getBlock()返回synchronized语句的块。TryTree.getBlock()返回try语句的块。MethodTree.getBody()返回方法主体,如果这是抽象方法或本机方法,则返回null。TryTree.getFinallyBlock()返回try语句中提供的 finally 块,如果没有则返回null。com.sun.source.tree 中的方法,参数类型为 BlockTree -
BlockTree 在 com.sun.source.util 中的用法
com.sun.source.util 中的方法,参数类型为 BlockTree修饰符和类型方法描述SimpleTreeVisitor.visitBlock(BlockTree node, P p) 访问BlockTree节点。TreeScanner.visitBlock(BlockTree node, P p) 访问BlockTree节点。