Skip to content

Commit 8589804

Browse files
committed
Link to known property name constants in SpringProperties
1 parent c649b74 commit 8589804

File tree

2 files changed

+17
-5
lines changed

2 files changed

+17
-5
lines changed

spring-core/src/main/java/org/springframework/core/SpringProperties.java

Lines changed: 7 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
* Copyright 2002-2020 the original author or authors.
2+
* Copyright 2002-2021 the original author or authors.
33
*
44
* Licensed under the Apache License, Version 2.0 (the "License");
55
* you may not use this file except in compliance with the License.
@@ -38,9 +38,14 @@
3838
*
3939
* @author Juergen Hoeller
4040
* @since 3.2.7
41-
* @see org.springframework.core.env.AbstractEnvironment#IGNORE_GETENV_PROPERTY_NAME
4241
* @see org.springframework.beans.CachedIntrospectionResults#IGNORE_BEANINFO_PROPERTY_NAME
42+
* @see org.springframework.context.index.CandidateComponentsIndexLoader#IGNORE_INDEX
43+
* @see org.springframework.core.env.AbstractEnvironment#IGNORE_GETENV_PROPERTY_NAME
44+
* @see org.springframework.expression.spel.SpelParserConfiguration#SPRING_EXPRESSION_COMPILER_MODE_PROPERTY_NAME
4345
* @see org.springframework.jdbc.core.StatementCreatorUtils#IGNORE_GETPARAMETERTYPE_PROPERTY_NAME
46+
* @see org.springframework.jndi.JndiLocatorDelegate#IGNORE_JNDI_PROPERTY_NAME
47+
* @see org.springframework.test.context.NestedTestConfiguration#ENCLOSING_CONFIGURATION_PROPERTY_NAME
48+
* @see org.springframework.test.context.TestConstructor#TEST_CONSTRUCTOR_AUTOWIRE_MODE_PROPERTY_NAME
4449
* @see org.springframework.test.context.cache.ContextCache#MAX_CONTEXT_CACHE_SIZE_PROPERTY_NAME
4550
*/
4651
public final class SpringProperties {

spring-expression/src/main/java/org/springframework/expression/spel/SpelParserConfiguration.java

Lines changed: 10 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
* Copyright 2002-2017 the original author or authors.
2+
* Copyright 2002-2021 the original author or authors.
33
*
44
* Licensed under the Apache License, Version 2.0 (the "License");
55
* you may not use this file except in compliance with the License.
@@ -30,10 +30,17 @@
3030
*/
3131
public class SpelParserConfiguration {
3232

33+
/**
34+
* System property that is used to configure the default compiler mode for
35+
* SpEL expression parsers: {@value}
36+
*/
37+
public static final String SPRING_EXPRESSION_COMPILER_MODE_PROPERTY_NAME = "spring.expression.compiler.mode";
38+
39+
3340
private static final SpelCompilerMode defaultCompilerMode;
3441

3542
static {
36-
String compilerMode = SpringProperties.getProperty("spring.expression.compiler.mode");
43+
String compilerMode = SpringProperties.getProperty(SPRING_EXPRESSION_COMPILER_MODE_PROPERTY_NAME);
3744
defaultCompilerMode = (compilerMode != null ?
3845
SpelCompilerMode.valueOf(compilerMode.toUpperCase()) : SpelCompilerMode.OFF);
3946
}
@@ -107,7 +114,7 @@ public SpelParserConfiguration(@Nullable SpelCompilerMode compilerMode, @Nullabl
107114

108115

109116
/**
110-
* Return the configuration mode for parsers using this configuration object.
117+
* Return the compiler mode for parsers using this configuration object.
111118
*/
112119
public SpelCompilerMode getCompilerMode() {
113120
return this.compilerMode;

0 commit comments

Comments
 (0)