本文整理汇总了Java中com.intellij.psi.formatter.xml.SyntheticBlock类的典型用法代码示例。如果您正苦于以下问题:Java SyntheticBlock类的具体用法?Java SyntheticBlock怎么用?Java SyntheticBlock使用的例子?那么, 这里精选的类代码示例或许可以为您提供帮助。
SyntheticBlock类属于com.intellij.psi.formatter.xml包,在下文中一共展示了SyntheticBlock类的3个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: getRealBlockParent
import com.intellij.psi.formatter.xml.SyntheticBlock; //导入依赖的package包/类
private BlockWithParent getRealBlockParent() {
BlockWithParent parent = getParent();
while (parent instanceof DataLanguageBlockWrapper && ((DataLanguageBlockWrapper) parent).getOriginal() instanceof SyntheticBlock) {
parent = parent.getParent();
}
return parent;
}
示例2: getRealBlockParent
import com.intellij.psi.formatter.xml.SyntheticBlock; //导入依赖的package包/类
private BlockWithParent getRealBlockParent() {
// if we can follow the chain of synthetic parent blocks, and if we end up
// at a real DataLanguage block (i.e. the synthetic blocks didn't lead to an DustFormatterBlock),
// we're a child of a templated language node and need an indent
BlockWithParent parent = getParent();
while (parent instanceof DataLanguageBlockWrapper
&& ((DataLanguageBlockWrapper) parent).getOriginal() instanceof SyntheticBlock) {
parent = parent.getParent();
}
return parent;
}
示例3: isSynthetic
import com.intellij.psi.formatter.xml.SyntheticBlock; //导入依赖的package包/类
private static boolean isSynthetic(BlockWithParent block) {
return block instanceof DataLanguageBlockWrapper && ((DataLanguageBlockWrapper) block)
.getOriginal() instanceof SyntheticBlock;
}