org.stjs.generator.check.statement
Class BlockInstanceCheck
java.lang.Object
org.stjs.generator.check.statement.BlockInstanceCheck
- All Implemented Interfaces:
- CheckContributor<com.sun.source.tree.BlockTree>, VisitorContributor<com.sun.source.tree.BlockTree,Void,GenerationContext<Void>,CheckVisitor>
public class BlockInstanceCheck
- extends Object
- implements CheckContributor<com.sun.source.tree.BlockTree>
this class checks that you cannot have instance initializer blocks (other than the one for special double brace
construction) as you can have only a constructor in a JavaScript class-like construction.
- Author:
- acraciun
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
BlockInstanceCheck
public BlockInstanceCheck()
isInitializationBlock
public static boolean isInitializationBlock(com.sun.source.util.TreePath path)
visit
public Void visit(CheckVisitor visitor,
com.sun.source.tree.BlockTree tree,
GenerationContext<Void> context)
- Specified by:
visit in interface VisitorContributor<com.sun.source.tree.BlockTree,Void,GenerationContext<Void>,CheckVisitor>
Copyright © 2014. All Rights Reserved.