List of usage examples for org.antlr.v4.runtime.misc Interval length
public int length()
From source file:org.tvl.goworks.editor.go.codemodel.impl.AbstractCodeElementModel.java
License:Open Source License
@CheckForNull protected static OffsetRegion getOffsetRegion(@NullAllowed ParseTree node) { if (node == null) { return null; }/*from w w w. j a v a 2 s .c o m*/ Interval sourceInterval = ParseTrees.getSourceInterval(node); return new OffsetRegion(sourceInterval.a, sourceInterval.length()); }