Package com.google.inject.internal
Class InternalFlags
java.lang.Object
com.google.inject.internal.InternalFlags
Contains flags for Guice.
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic enumOptions for controlling whether Guice uses bytecode generation at runtime.static enumOptions for enable or disable using ansi color in error messages.static enumThe options for Guice custom class loading.static enumThe options for Guice stack trace collection.static enumOptions for handling nullable parameters used in provides methods. -
Field Summary
FieldsModifier and TypeFieldDescriptionprivate static final InternalFlags.BytecodeGenOptionprivate static final InternalFlags.ColorizeOptionprivate static final InternalFlags.CustomClassLoadingOptionprivate static final InternalFlags.IncludeStackTraceOptionprivate static final Loggerprivate static final InternalFlags.NullableProvidesOption -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic booleanprivate static <T extends Enum<T>>
TgetSystemOption(String name, T defaultValue) Gets the system option indicated by the specified key; runs as a privileged action.private static <T extends Enum<T>>
TgetSystemOption(String name, T defaultValue, T secureValue) Gets the system option indicated by the specified key; runs as a privileged action.static boolean
-
Field Details
-
logger
-
INCLUDE_STACK_TRACES
-
CUSTOM_CLASS_LOADING
-
NULLABLE_PROVIDES
-
BYTECODE_GEN_OPTION
-
COLORIZE_OPTION
-
-
Constructor Details
-
InternalFlags
private InternalFlags()
-
-
Method Details
-
getIncludeStackTraceOption
-
getCustomClassLoadingOption
-
getNullableProvidesOption
-
isBytecodeGenEnabled
public static boolean isBytecodeGenEnabled() -
enableColorizeErrorMessages
public static boolean enableColorizeErrorMessages() -
getSystemOption
Gets the system option indicated by the specified key; runs as a privileged action.- Parameters:
name- of the system optiondefaultValue- if the option is not set- Returns:
- value of the option, defaultValue if not set
-
getSystemOption
Gets the system option indicated by the specified key; runs as a privileged action.- Parameters:
name- of the system optiondefaultValue- if the option is not setsecureValue- if the security manager disallows access to the option- Returns:
- value of the option, defaultValue if not set, secureValue if no access
-