java.lang.Object
com.intellij.lang.BracePair
Defines a single pair of braces which need to be matched when editing code in a custom language.
- 另请参阅:
-
构造器概要
构造器构造器说明BracePair(IElementType leftBrace, IElementType rightBrace, boolean structural) Creates a new brace pair instance. -
方法概要
-
构造器详细资料
-
BracePair
Creates a new brace pair instance.- 参数:
leftBrace- the lexer token type for the left brace in the pair.rightBrace- the lexer token type for the right brace in the pair.structural- if true, the brace is considered structural (seeisStructural()for details)
-
-
方法详细资料
-
getLeftBraceType
Returns the lexer token type for the left brace in the pair.- 返回:
- token type
-
getRightBraceType
Returns the lexer token type for the right brace in the pair.- 返回:
- token type
-
isStructural
public boolean isStructural()Returns true if the brace is structural. Structural braces have higher priority than regular braces: they are matched with each other even if there are unmatched braces of other types between them, and an opening non-structural brace is not matched with a closing one if one of them is outside a pair of matched structural braces and another is outside. In Java code, the curly braces are structural.- 返回:
- true if the brace is structural, false otherwise.
-
toString
-