Class WebAppClassLoading
Class loading of web application:
- Protected (a.k.a. System) classes are classes typically provided by the JVM, that cannot be replaced by the web application, and they are always loaded via the environment or system classloader. They are visible but protected.
 - Hidden (a.k.a. Server) classes are those used to implement the Server and are not made available to the
        web application. They are hidden from the web application 
ClassLoader. 
These protections are set to reasonable defaults DEFAULT_PROTECTED_CLASSES and DEFAULT_HIDDEN_CLASSES,
which may be programmatically configured and will affect the defaults applied to all web applications in the same JVM.
The defaults applied by a specific Server can be configured using addProtectedClasses(Server, String...) and
addHiddenClasses(Server, String...). Alternately the Server attributes PROTECTED_CLASSES_ATTRIBUTE
and HIDDEN_CLASSES_ATTRIBUTE may be used to direct set a ClassMatcher to use for all web applications
within the server instance.
The defaults applied by a specific Environment can be configured using addProtectedClasses(Environment, String...) and
addHiddenClasses(Environment, String...). Alternately the Environment attributes PROTECTED_CLASSES_ATTRIBUTE
and HIDDEN_CLASSES_ATTRIBUTE may be used to direct set a ClassMatcher to use for all web applications
within the server instance.
Ultimately, the configurations set by this class only affects the defaults applied to each web application 
Context and the ClassMatcher fields of the web applications
can be directly access to configure a specific context.
- 
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final ClassMatcherThe default hidden (server) classes used by a web application, which can be applied to theClassMatchers created bygetHiddenClasses(Environment).static final ClassMatcherThe default protected (system) classes used by a web application, which will be applied to theClassMatchers created bygetProtectedClasses(Environment).static final Stringstatic final String - 
Constructor Summary
Constructors - 
Method Summary
Modifier and TypeMethodDescriptionstatic voidaddHiddenClasses(String... patterns) Add a hidden (server) Class pattern to use for all WebAppContexts of a givenServer.static voidaddHiddenClasses(Server server, String... patterns) Add a hidden (server) Class pattern to use for all WebAppContexts of a givenServer.static voidaddHiddenClasses(Attributes attributes, String... patterns) Add a hidden (server) Class pattern to use for all WebAppContexts of a givenServer.static voidaddHiddenClasses(Environment environment, String... patterns) Add a hidden (server) Class pattern to use for all ee9 WebAppContexts.static voidaddProtectedClasses(String... patterns) Add a protected (system) Class pattern to use for all WebAppContexts.static voidaddProtectedClasses(Server server, String... patterns) Add a protected (system) Class pattern to use for all WebAppContexts of a givenServer.static voidaddProtectedClasses(Attributes attributes, String... patterns) Add a protected (system) Class pattern to use for all WebAppContexts of a givenServer.static voidaddProtectedClasses(Environment environment, String... patterns) Add a protected (system) Class pattern to use for WebAppContexts of a given environment.static ClassMatchergetHiddenClasses(Server server) Get the default hidden (server) classes for aServerstatic ClassMatchergetHiddenClasses(Environment environment) Get the default hidden (server) classes for anEnvironmentstatic ClassMatchergetProtectedClasses(Server server) Get the default protected (system) classes for aServerstatic ClassMatchergetProtectedClasses(Environment environment) Get the default protected (system) classes for anEnvironment 
- 
Field Details
- 
PROTECTED_CLASSES_ATTRIBUTE
- See Also:
 
 - 
HIDDEN_CLASSES_ATTRIBUTE
- See Also:
 
 - 
DEFAULT_PROTECTED_CLASSES
The default protected (system) classes used by a web application, which will be applied to theClassMatchers created bygetProtectedClasses(Environment). - 
DEFAULT_HIDDEN_CLASSES
The default hidden (server) classes used by a web application, which can be applied to theClassMatchers created bygetHiddenClasses(Environment). 
 - 
 - 
Constructor Details
- 
WebAppClassLoading
public WebAppClassLoading() 
 - 
 - 
Method Details
- 
getProtectedClasses
Get the default protected (system) classes for aServer - 
getProtectedClasses
Get the default protected (system) classes for anEnvironment- Parameters:
 environment- TheServerfor the defaults- Returns:
 - The default protected (system) classes for the 
Environment, which will be theDEFAULT_PROTECTED_CLASSESif not previously configured. 
 - 
addProtectedClasses
Add a protected (system) Class pattern to use for all WebAppContexts.- Parameters:
 patterns- the patterns to use
 - 
addProtectedClasses
Add a protected (system) Class pattern to use for all WebAppContexts of a givenServer.- Parameters:
 attributes- TheAttributesinstance to add classes topatterns- the patterns to use
 - 
addProtectedClasses
 - 
addProtectedClasses
Add a protected (system) Class pattern to use for WebAppContexts of a given environment.- Parameters:
 environment- TheEnvironmentinstance to add classes topatterns- the patterns to use
 - 
getHiddenClasses
Get the default hidden (server) classes for aServer - 
getHiddenClasses
Get the default hidden (server) classes for anEnvironment- Parameters:
 environment- TheServerfor the defaults- Returns:
 - The default hidden (server) classes for the 
Environment, which will beDEFAULT_PROTECTED_CLASSESif not previously configured. 
 - 
addHiddenClasses
 - 
addHiddenClasses
Add a hidden (server) Class pattern to use for all WebAppContexts of a givenServer.- Parameters:
 attributes- TheAttributesinstance to add classes topatterns- the patterns to use
 - 
addHiddenClasses
 - 
addHiddenClasses
Add a hidden (server) Class pattern to use for all ee9 WebAppContexts.- Parameters:
 environment- TheEnvironmentinstance to add classes topatterns- the patterns to use
 
 -