public class PortalContainerConfig extends Object implements Startable
RootContainer to allows to understand how to manage and
deploy all the portal containers
Created by The eXo Platform SAS
Author : Nicolas Filotto
nicolas.filotto@exoplatform.com
26 ao�t 2009| Modifier and Type | Field and Description |
|---|---|
static String |
DEFAULT_PORTAL_CONTAINER_NAME
The default name of a portal container
|
static String |
DEFAULT_REALM_NAME
The default realm name
|
static String |
DEFAULT_REST_CONTEXT_NAME
The default name of a the
ServletContext of the rest web application |
static String |
PORTAL_CONTAINER_SETTING_NAME
The name of the setting corresponding to the portal container name
|
static String |
REALM_SETTING_NAME
The name of the setting corresponding to the relam name
|
static String |
REST_CONTEXT_SETTING_NAME
The name of the setting corresponding to the rest context name
|
| Constructor and Description |
|---|
PortalContainerConfig(ConfigurationManager cm) |
PortalContainerConfig(ConfigurationManager cm,
J2EEServerInfo serverInfo) |
PortalContainerConfig(ConfigurationManager cm,
J2EEServerInfo serverInfo,
PropertyConfigurator pc) |
PortalContainerConfig(ConfigurationManager cm,
PropertyConfigurator pc) |
PortalContainerConfig(InitParams params,
ConfigurationManager cm) |
PortalContainerConfig(InitParams params,
ConfigurationManager cm,
J2EEServerInfo serverInfo) |
PortalContainerConfig(InitParams params,
ConfigurationManager cm,
J2EEServerInfo serverInfo,
PropertyConfigurator pc)
We add the
PropertyConfigurator in the constructor, in order to make sure that it is
created before since it could define some JVM parameters that could be used internally by the
PortalContainerConfig |
PortalContainerConfig(InitParams params,
ConfigurationManager cm,
PropertyConfigurator pc) |
| Modifier and Type | Method and Description |
|---|---|
void |
disablePortalContainer(String name)
Disables a portal container if it has not yet been disabled.
|
String |
getDefaultPortalContainer() |
String |
getDefaultRealmName() |
String |
getDefaultRestContext() |
List<String> |
getDependencies(String portalContainerName)
Gives all the dependencies related to the given portal container
|
String |
getPortalContainerName(String contextName)
Gives the portal container names for which the web application is available if several
portal container are available only the fist one will be returned
|
List<String> |
getPortalContainerNames(String contextName)
Gives the list of all the portal container names for which the web application is available
|
String |
getRealmName(String portalContainerName)
Gives the name of the realm related to the given portal container
|
String |
getRestContextName(String portalContainerName)
Gives the name of the rest
ServletContext related to the given portal container |
Object |
getSetting(String portalContainerName,
String settingName)
Give the value of a given setting for a given portal container name
|
boolean |
hasDefinition()
Indicates if at least one portal container definition has been defined.
|
boolean |
isPortalContainerName(String name)
Indicates if the given name is the name of a registered portal container
|
boolean |
isPortalContainerNameDisabled(String name)
Indicates if the given name is the name of a portal container that has been registered as disabled
|
boolean |
isScopeValid(String portalContainerName,
String contextName)
Indicates if the given servlet context is a dependency of the given portal container
|
void |
registerChangePlugin(PortalContainerDefinitionChangePlugin plugin)
Allow to define a set of changes to apply to the registered
PortalContainerDefinition |
void |
registerDisablePlugin(PortalContainerDefinitionDisablePlugin plugin)
Allow to disable a set of portal containers
|
void |
registerPlugin(PortalContainerDefinitionPlugin plugin)
Allow to define a set of
PortalContainerDefinition |
void |
registerPortalContainerName(String name)
Registers a name of a portal container if it has not yet been registered
|
void |
start()
Start this component.
|
void |
stop()
Stop this component.
|
void |
unregisterPortalContainerName(String name)
Unregisters a name of a portal container if it has not yet been unregistered
|
public static final String PORTAL_CONTAINER_SETTING_NAME
public static final String REST_CONTEXT_SETTING_NAME
public static final String REALM_SETTING_NAME
public static final String DEFAULT_PORTAL_CONTAINER_NAME
public static final String DEFAULT_REST_CONTEXT_NAME
ServletContext of the rest web applicationpublic static final String DEFAULT_REALM_NAME
public PortalContainerConfig(ConfigurationManager cm)
public PortalContainerConfig(ConfigurationManager cm, PropertyConfigurator pc)
public PortalContainerConfig(ConfigurationManager cm, J2EEServerInfo serverInfo)
public PortalContainerConfig(ConfigurationManager cm, J2EEServerInfo serverInfo, PropertyConfigurator pc)
public PortalContainerConfig(InitParams params, ConfigurationManager cm)
public PortalContainerConfig(InitParams params, ConfigurationManager cm, PropertyConfigurator pc)
public PortalContainerConfig(InitParams params, ConfigurationManager cm, J2EEServerInfo serverInfo)
public PortalContainerConfig(InitParams params, ConfigurationManager cm, J2EEServerInfo serverInfo, PropertyConfigurator pc)
PropertyConfigurator in the constructor, in order to make sure that it is
created before since it could define some JVM parameters that could be used internally by the
PortalContainerConfigpublic String getDefaultPortalContainer()
public String getDefaultRestContext()
ServletContextpublic String getDefaultRealmName()
public boolean hasDefinition()
true if at least one definition has been set, false otherwisepublic void disablePortalContainer(String name)
name - the name of the portal container to disablepublic boolean isPortalContainerNameDisabled(String name)
name - the name to checktrue if the name is a name of a disabled portal container, false
otherwise.public void registerPortalContainerName(String name)
name - the name of the portal container to registerpublic void unregisterPortalContainerName(String name)
name - the name of the portal container to registerpublic boolean isPortalContainerName(String name)
name - the name to checktrue if the name is a name of a portal container, false
otherwise.public List<String> getPortalContainerNames(String contextName)
contextName - the context name of the web applicationpublic String getPortalContainerName(String contextName)
contextName - the context name of the web applicationpublic List<String> getDependencies(String portalContainerName)
portalContainerName - the name of the portal container for which we want the dependenciespublic Object getSetting(String portalContainerName, String settingName)
portalContainerName - the name of the portal container for which we want the value of the
settingsettingName - the name of the setting that we seeknull if it cans not be found.public String getRestContextName(String portalContainerName)
ServletContext related to the given portal containerportalContainerName - the name of the portal container for which we want the rest context namePortalContainerDefinition
if it has not been set it will return defaultDefinition.getRestContextName()public String getRealmName(String portalContainerName)
portalContainerName - the name of the portal container for which we want the realm namePortalContainerDefinition
if it has not been set it will return defaultDefinition.getRealmName()public boolean isScopeValid(String portalContainerName, String contextName)
portalContainerName - the name of the portal containercontextName - the name of the ServletContexttrue if the dependencies matches, false otherwise;public void registerPlugin(PortalContainerDefinitionPlugin plugin)
PortalContainerDefinitionplugin - the plugin that contains all the PortalContainerDefinition to definepublic void registerDisablePlugin(PortalContainerDefinitionDisablePlugin plugin)
plugin - the plugin that defines the name of portal containers to disablepublic void registerChangePlugin(PortalContainerDefinitionChangePlugin plugin)
PortalContainerDefinitionplugin - the plugin that defines the changes to applypublic void start()
public void stop()
Disposable if you need a single call at the definite end of the lifecycle.Copyright © 2020 eXo Platform SAS. All Rights Reserved.