예제 #1
0
        public JcaExecutorServiceManagedConnection(JcaExecutorServiceManagedConnectionFactory mcf)
        {
            this.mcf        = mcf;
            this.logwriter  = null;
            this.listeners  = Collections.synchronizedList(new List <ConnectionEventListener>(1));
            this.connection = null;
            JcaExecutorServiceConnector ra = (JcaExecutorServiceConnector)mcf.ResourceAdapter;

            @delegate = (ExecutorService)ra.getExecutorServiceWrapper().ExecutorService;
        }
예제 #2
0
//JAVA TO C# CONVERTER WARNING: Method 'throws' clauses are not available in .NET:
//ORIGINAL LINE: public void associateConnection(Object connection) throws javax.resource.ResourceException
        public virtual void associateConnection(object connection)
        {
            if (connection == null)
            {
                throw new ResourceException("Null connection handle");
            }
            if (!(connection is JcaExecutorServiceConnectionImpl))
            {
                throw new ResourceException("Wrong connection handle");
            }
            this.connection = (JcaExecutorServiceConnectionImpl)connection;
        }
예제 #3
0
//JAVA TO C# CONVERTER WARNING: Method 'throws' clauses are not available in .NET:
//ORIGINAL LINE: public Object getConnection(javax.security.auth.Subject subject, javax.resource.spi.ConnectionRequestInfo cxRequestInfo) throws javax.resource.ResourceException
        public virtual object getConnection(Subject subject, ConnectionRequestInfo cxRequestInfo)
        {
            connection = new JcaExecutorServiceConnectionImpl(this, mcf);
            return(connection);
        }