Package com.sun.enterprise.v3.server
Class ServerContextImpl
- java.lang.Object
-
- com.sun.enterprise.v3.server.ServerContextImpl
-
- All Implemented Interfaces:
org.glassfish.hk2.api.PostConstruct
,ServerContext
@Service @Singleton public class ServerContextImpl extends Object implements ServerContext, org.glassfish.hk2.api.PostConstruct
This is the Server Context object.- Author:
- Jerome Dochez
-
-
Constructor Summary
Constructors Constructor Description ServerContextImpl()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description String[]
getCmdLineArgs()
Get the server command-line argumentsClassLoader
getCommonClassLoader()
Get the classloader that loads .jars in $instance/lib and classes in $instance/lib/classes.Server
getConfigBean()
Get the server configuration bean.String
getDefaultDomainName()
get the default domain nameorg.glassfish.hk2.api.ServiceLocator
getDefaultServices()
Returns the default services for this instanceInitialContext
getInitialContext()
Get the initial naming context.File
getInstallRoot()
Get server install rootString
getInstanceName()
Get the server instance nameFile
getInstanceRoot()
InvocationManager
getInvocationManager()
get the J2EE Server invocation managerClassLoader
getLifecycleParentClassLoader()
Get the parent class loader for the life cycle modules.String
getServerConfigURL()
Get a URL representation of server configurationClassLoader
getSharedClassLoader()
Returns the shared class loader for this server instance.void
postConstruct()
Creates a new instance of ServerContextImpl
-
-
-
Method Detail
-
postConstruct
public void postConstruct()
Creates a new instance of ServerContextImpl- Specified by:
postConstruct
in interfaceorg.glassfish.hk2.api.PostConstruct
-
getInstanceRoot
public File getInstanceRoot()
-
getCmdLineArgs
public String[] getCmdLineArgs()
Description copied from interface:ServerContext
Get the server command-line arguments- Specified by:
getCmdLineArgs
in interfaceServerContext
- Returns:
- the server command-line arguments
-
getInstallRoot
public File getInstallRoot()
Description copied from interface:ServerContext
Get server install root- Specified by:
getInstallRoot
in interfaceServerContext
- Returns:
- the server install root
-
getInstanceName
public String getInstanceName()
Description copied from interface:ServerContext
Get the server instance name- Specified by:
getInstanceName
in interfaceServerContext
- Returns:
- the server instance name
-
getServerConfigURL
public String getServerConfigURL()
Description copied from interface:ServerContext
Get a URL representation of server configuration- Specified by:
getServerConfigURL
in interfaceServerContext
- Returns:
- the URL to the server configuration
-
getConfigBean
public Server getConfigBean()
Description copied from interface:ServerContext
Get the server configuration bean.- Specified by:
getConfigBean
in interfaceServerContext
- Returns:
- the server config bean
-
getInitialContext
public InitialContext getInitialContext()
Description copied from interface:ServerContext
Get the initial naming context.- Specified by:
getInitialContext
in interfaceServerContext
- Returns:
- the initial naming context
-
getCommonClassLoader
public ClassLoader getCommonClassLoader()
Description copied from interface:ServerContext
Get the classloader that loads .jars in $instance/lib and classes in $instance/lib/classes.- Specified by:
getCommonClassLoader
in interfaceServerContext
- Returns:
- the common class loader for this instance
-
getSharedClassLoader
public ClassLoader getSharedClassLoader()
Description copied from interface:ServerContext
Returns the shared class loader for this server instance.- Specified by:
getSharedClassLoader
in interfaceServerContext
- Returns:
- the shared class loader
-
getLifecycleParentClassLoader
public ClassLoader getLifecycleParentClassLoader()
Description copied from interface:ServerContext
Get the parent class loader for the life cycle modules.- Specified by:
getLifecycleParentClassLoader
in interfaceServerContext
- Returns:
- the parent class loader for the life cycle modules
-
getInvocationManager
public InvocationManager getInvocationManager()
Description copied from interface:ServerContext
get the J2EE Server invocation manager- Specified by:
getInvocationManager
in interfaceServerContext
- Returns:
- InvocationManager
-
getDefaultDomainName
public String getDefaultDomainName()
Description copied from interface:ServerContext
get the default domain name- Specified by:
getDefaultDomainName
in interfaceServerContext
- Returns:
- String default domain name
-
getDefaultServices
public org.glassfish.hk2.api.ServiceLocator getDefaultServices()
Returns the default services for this instance- Specified by:
getDefaultServices
in interfaceServerContext
- Returns:
- default services
-
-