Package com._1c.g5.v8.dt.bsl.resource
Class PreprocessorEnvironmentsComputer
java.lang.Object
com._1c.g5.v8.dt.bsl.resource.PreprocessorEnvironmentsComputer
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic void
computeEnvironments
(IfPreprocessor preprocessor, boolean intersectWithParent, Version version) ComputeEnvironments
for BslIfPreprocessor
parts.static Environments
static boolean
Define thatPreprocessorLiteralExpression
containsenv
-
Constructor Details
-
PreprocessorEnvironmentsComputer
public PreprocessorEnvironmentsComputer()
-
-
Method Details
-
computeEnvironments
public static void computeEnvironments(IfPreprocessor preprocessor, boolean intersectWithParent, Version version) ComputeEnvironments
for BslIfPreprocessor
parts. ComputeEnvironments
for each part ofIfPreprocessor
and result intersect with parentEnvironmental
element'sEnvironments
- Parameters:
preprocessor
- can't benull
intersectWithParent
- iftrue
we need to intersectEnvironments
forPreprocessorIfConditional
with parentEnvironmental
version
- actualVersion
, can't benull
- Throws:
IllegalArgumentException
-
isPreprocessorLiteralContainEnv
public static boolean isPreprocessorLiteralContainEnv(PreprocessorLiteralExpression literal, Environment env) Define thatPreprocessorLiteralExpression
containsenv
- Parameters:
literal
-PreprocessorLiteralExpression
env
-Environment
- Returns:
true
, if contains,false
if doesn't contain or literal or env isnull
-
getEnvironmentsByPreprocessorLiteral
public static Environments getEnvironmentsByPreprocessorLiteral(PreprocessorLiteralExpression literal) - Parameters:
literal
-PreprocessorLiteralExpression
- Returns:
- corresponding
Environments
-