Class RemoteNamingContextFactory

    • Constructor Detail

      • RemoteNamingContextFactory

        public RemoteNamingContextFactory()
        Construct a new instance.
    • Method Detail

      • supportsUriScheme

        public boolean supportsUriScheme​(NamingProvider namingProvider,
                                         String nameScheme)
        Description copied from interface: NamingContextFactory
        Determine if this factory supports the given provider and name scheme. This method is called when a JNDI operation is executed on an initial context to determine which provider should handle the operation.

        A context factory should evaluate the provider's type to determine if the provider is compatible with the naming scheme, and should not support producing contexts for unknown providers.

        Specified by:
        supportsUriScheme in interface NamingContextFactory
        Parameters:
        namingProvider - the naming provider which is handling this request, or null if it is local
        nameScheme - the JNDI name scheme, or null if no name scheme was given
        Returns:
        true if this factory supports the given scheme, false otherwise
      • createRootContext

        public Context createRootContext​(NamingProvider namingProvider,
                                         String nameScheme,
                                         FastHashtable<String,​Object> env,
                                         ProviderEnvironment providerEnvironment)
                                  throws NamingException
        Description copied from interface: NamingContextFactory
        Create the root context for this naming scheme. The context should capture any locally relevant information, such as the relevant local security or authentication context.
        Specified by:
        createRootContext in interface NamingContextFactory
        Parameters:
        namingProvider - the naming provider which is handling this request, or null if it is local
        nameScheme - the scheme in the name, or null if there is no name URL scheme
        env - a copy of the environment which may be consumed directly by the provider (not null)
        providerEnvironment - the provider environment (not null)
        Returns:
        the root context (must not be null)
        Throws:
        NamingException - if the root context creation failed for some reason