Class 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 Detail

      • ServerContextImpl

        public ServerContextImpl()
    • Method Detail

      • postConstruct

        public void postConstruct()
        Creates a new instance of ServerContextImpl
        Specified by:
        postConstruct in interface org.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 interface ServerContext
        Returns:
        the server command-line arguments
      • getServerConfigURL

        public String getServerConfigURL()
        Description copied from interface: ServerContext
        Get a URL representation of server configuration
        Specified by:
        getServerConfigURL in interface ServerContext
        Returns:
        the URL to the server configuration
      • 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 interface ServerContext
        Returns:
        the common class loader for this instance
      • getDefaultServices

        public org.glassfish.hk2.api.ServiceLocator getDefaultServices()
        Returns the default services for this instance
        Specified by:
        getDefaultServices in interface ServerContext
        Returns:
        default services