Package com._1c.g5.v8.dt.internal.bsl.ui
Enum Class ProceduralBracketsServiceProvider.ProceduralBracket
java.lang.Object
java.lang.Enum<ProceduralBracketsServiceProvider.ProceduralBracket>
com._1c.g5.v8.dt.internal.bsl.ui.ProceduralBracketsServiceProvider.ProceduralBracket
- All Implemented Interfaces:
Serializable,Comparable<ProceduralBracketsServiceProvider.ProceduralBracket>,Constable
- Enclosing class:
- ProceduralBracketsServiceProvider
public static enum ProceduralBracketsServiceProvider.ProceduralBracket
extends Enum<ProceduralBracketsServiceProvider.ProceduralBracket>
Short presentation of procedural brackets (such as if-else-endif, while-enddo, try-except-endtry and etc) from Built-In language
-
Nested Class Summary
Nested classes/interfaces inherited from class java.lang.Enum
Enum.EnumDesc<E extends Enum<E>> -
Enum Constant Summary
Enum Constants -
Method Summary
Modifier and TypeMethodDescriptiongetBracketByTokenType(int type) GetsProceduralBracketsServiceProvider.ProceduralBracketby type ofDocumentTokenSource.TokenAdapterGets for close or middle procedural bracket its open bracket.booleanChecks that bracket is close, for example "endif", "enddo", "endtry" are close procedural bracketbooleanChecks that bracket is middle, for example "else", "except" are middle procedural bracketbooleanChecks that bracket is open, for example "if", "while", "for", "try" are open procedural bracketReturns the enum constant of this class with the specified name.values()Returns an array containing the constants of this enum class, in the order they are declared.
-
Enum Constant Details
-
IF
-
ELSE_IF
-
ELSE
-
END_IF
-
FOR
-
WHILE
-
END_DO
-
TRY
-
EXCEPT
-
END_TRY
-
FUNCTION
-
END_FUNCTION
-
PROCEDURE
-
END_PROCEDURE
-
-
Method Details
-
values
Returns an array containing the constants of this enum class, in the order they are declared.- Returns:
- an array containing the constants of this enum class, in the order they are declared
-
valueOf
Returns the enum constant of this class with the specified name. The string must match exactly an identifier used to declare an enum constant in this class. (Extraneous whitespace characters are not permitted.)- Parameters:
name- the name of the enum constant to be returned.- Returns:
- the enum constant with the specified name
- Throws:
IllegalArgumentException- if this enum class has no constant with the specified nameNullPointerException- if the argument is null
-
getBracketByTokenType
GetsProceduralBracketsServiceProvider.ProceduralBracketby type ofDocumentTokenSource.TokenAdapter- Parameters:
type-DocumentTokenSource.TokenAdapter.getLexerTokenType()fromInternalBslLexer- Returns:
- corresponding to the
DocumentTokenSource.TokenAdapter.getLexerTokenType()ProceduralBracketsServiceProvider.ProceduralBracketornullif bracket was not found
-
getOpenBrackets
Gets for close or middle procedural bracket its open bracket. For example for "endif" bracket open bracket is "if".- Returns:
- set of open procedural brackets for current close or middle bracket. If current bracket is open empty set will be returnes. Never
null
-
isMiddleBracket
public boolean isMiddleBracket()Checks that bracket is middle, for example "else", "except" are middle procedural bracket- Returns:
trueif it is middle procedural bracket,falseotherwise
-
isCloseBracket
public boolean isCloseBracket()Checks that bracket is close, for example "endif", "enddo", "endtry" are close procedural bracket- Returns:
trueif it is close (end) procedural bracket,falseotherwise
-
isOpenBracket
public boolean isOpenBracket()Checks that bracket is open, for example "if", "while", "for", "try" are open procedural bracket- Returns:
trueif it is open (start) procedural bracket,falseotherwise
-