Class DataSourceLinkFactory

  • All Implemented Interfaces:
    javax.naming.spi.ObjectFactory

    public class DataSourceLinkFactory
    extends ResourceLinkFactory

    Object factory for resource links for shared data sources.

    • Constructor Detail

      • DataSourceLinkFactory

        public DataSourceLinkFactory()
    • Method Detail

      • setGlobalContext

        public static void setGlobalContext​(javax.naming.Context newGlobalContext)
      • getObjectInstance

        public java.lang.Object getObjectInstance​(java.lang.Object obj,
                                                  javax.naming.Name name,
                                                  javax.naming.Context nameCtx,
                                                  java.util.Hashtable<?,​?> environment)
                                           throws javax.naming.NamingException
        Create a new DataSource instance.
        Specified by:
        getObjectInstance in interface javax.naming.spi.ObjectFactory
        Overrides:
        getObjectInstance in class ResourceLinkFactory
        Parameters:
        obj - The reference object describing the DataSource
        Throws:
        javax.naming.NamingException
      • wrapDataSource

        protected java.lang.Object wrapDataSource​(java.lang.Object datasource,
                                                  java.lang.String username,
                                                  java.lang.String password)
                                           throws javax.naming.NamingException
        Throws:
        javax.naming.NamingException