aboutsummaryrefslogtreecommitdiff
path: root/src/core
diff options
context:
space:
mode:
authorRoel Spilker <r.spilker@gmail.com>2014-01-19 02:23:14 +0100
committerRoel Spilker <r.spilker@gmail.com>2014-01-19 02:23:14 +0100
commit513a27f746e5744fe800147e274ed6cfac90f45c (patch)
tree5dd1f6c397418d2dc5d7c6cb2f82b76f614c29c5 /src/core
parent5767628efeb66644827f89861425ff173803b9ad (diff)
downloadlombok-513a27f746e5744fe800147e274ed6cfac90f45c.tar.gz
lombok-513a27f746e5744fe800147e274ed6cfac90f45c.tar.bz2
lombok-513a27f746e5744fe800147e274ed6cfac90f45c.zip
[configuration] Make sure the ConfigurationKeys class is initialized
Diffstat (limited to 'src/core')
-rw-r--r--src/core/lombok/ConfigurationKeys.java15
-rw-r--r--src/core/lombok/eclipse/HandlerLibrary.java2
-rw-r--r--src/core/lombok/javac/HandlerLibrary.java2
3 files changed, 17 insertions, 2 deletions
diff --git a/src/core/lombok/ConfigurationKeys.java b/src/core/lombok/ConfigurationKeys.java
index 8e90877b..cd8e0717 100644
--- a/src/core/lombok/ConfigurationKeys.java
+++ b/src/core/lombok/ConfigurationKeys.java
@@ -30,6 +30,11 @@ import lombok.core.configuration.ConfigurationKey;
public class ConfigurationKeys {
private ConfigurationKeys() {}
+ /**
+ * Makes sure all {@link ConfigurationKey}s in this class are loaded.
+ */
+ public static void ensureKeysLoaded() {};
+
// ##### main package features #####
// ----- *ArgsConstructor -----
@@ -297,4 +302,14 @@ public class ConfigurationKeys {
* If set, <em>any</em> usage of {@code @Value} results in a warning / error.
*/
public static final ConfigurationKey<FlagUsageType> WITHER_FLAG_USAGE = new ConfigurationKey<FlagUsageType>("lombok.Wither.flagUsage") {};
+
+
+ /**
+ * lombok configuration: {@code stop-bubbling} = {@code true} | {@code false}.
+ *
+ * If not set, or set to {@code false}, the configuration system will look for {@code lombok.config} files in the parent directory.
+ *
+ * If set to {@code true}, no futher {@code lombok.config} files will be checked.
+ */
+ public static final ConfigurationKey<Boolean> STOP_BUBBLING = new ConfigurationKey<Boolean>("stop-bubbling") {};
}
diff --git a/src/core/lombok/eclipse/HandlerLibrary.java b/src/core/lombok/eclipse/HandlerLibrary.java
index 78c24ebd..1eb3c13a 100644
--- a/src/core/lombok/eclipse/HandlerLibrary.java
+++ b/src/core/lombok/eclipse/HandlerLibrary.java
@@ -56,7 +56,7 @@ import org.eclipse.jdt.internal.compiler.ast.TypeReference;
*/
public class HandlerLibrary {
static {
- ConfigurationKeys.class.getClass();
+ ConfigurationKeys.ensureKeysLoaded();
}
/**
diff --git a/src/core/lombok/javac/HandlerLibrary.java b/src/core/lombok/javac/HandlerLibrary.java
index 6994836b..e28033c9 100644
--- a/src/core/lombok/javac/HandlerLibrary.java
+++ b/src/core/lombok/javac/HandlerLibrary.java
@@ -55,7 +55,7 @@ import com.sun.tools.javac.tree.JCTree.JCCompilationUnit;
*/
public class HandlerLibrary {
static {
- ConfigurationKeys.class.getClass();
+ ConfigurationKeys.ensureKeysLoaded();
}
private final TypeLibrary typeLibrary = new TypeLibrary();