ilog.rules.res.session

Class IlrEJB3SessionFactory

  • java.lang.Object
    • ilog.rules.res.session.impl.IlrSessionFactoryBase
      • ilog.rules.res.session.IlrEJB3SessionFactory
  • All Implemented Interfaces:
    IlrSessionFactory


    public class IlrEJB3SessionFactory
    extends ilog.rules.res.session.impl.IlrSessionFactoryBase
    IlrEJB3SessionFactory is a session factory for EJB3 rule sessions. This class provides access to enterprise beans through the common rule session interfaces.
    Since:
    7.0
    • Method Summary

      Methods 
      Modifier and Type Method and Description
      IlrManagementSession createManagementSession()
      Management sessions are not available when using the EJB packaging, this method always throws an UnsupportedOperationException.
      IlrStatefulSession createStatefulSession(IlrPath rulesetPath, java.io.Serializable userData, java.util.Map<java.lang.String,java.lang.Object> initParameters, boolean forceUptodate)
      Finds a reference to an initialized stateful EJB3 rule session bean.
      IlrStatefulSession createStatefulSession(IlrPath rulesetPath, java.io.Serializable userData, java.util.Map<java.lang.String,java.lang.Object> initParameters, boolean forceUptodate, boolean enableInterceptor)
      Finds a reference to an initialized stateful EJB3 rule session bean.
      IlrStatelessSession createStatelessSession()
      Finds a reference to a stateless EJB3 rule session Bean.
      java.lang.String getStatefulLocalJndiName()
      Returns the JNDI name for the local stateful session.
      java.lang.String getStatefulRemoteJndiName()
      Returns JNDI name for the remote stateful session.
      java.lang.String getStatelessLocalJndiName()
      Returns the JNDI name for the local stateless session.
      java.lang.String getStatelessRemoteJndiName()
      Returns the JNDI name for the remote stateless session.
      boolean isRemote()
      Checks if remote EJBs are being used.
      void setRemote(boolean remote)
      Sets the remote flag for this rule session factory.
      void setStatefulLocalJndiName(java.lang.String statefulLocalJndiName)
      Sets the JNDI name for the local stateful session.
      void setStatefulRemoteJndiName(java.lang.String statefulRemoteJndiName)
      Sets the JNDI name for the remote stateful session.
      void setStatelessLocalJndiName(java.lang.String statelessLocalJndiName)
      Sets JNDI name for the local stateless session.
      void setStatelessRemoteJndiName(java.lang.String statelessRemoteJndiName)
      Sets the JNDI name for the remote stateless session.
      • Methods inherited from class ilog.rules.res.session.impl.IlrSessionFactoryBase

        createRequest, createTraceDAOFactory, getXUInfo, isInterceptorEnabled, setInterceptorEnabled
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Constructor Detail

      • IlrEJB3SessionFactory

        public IlrEJB3SessionFactory(java.util.Hashtable<?,?> jndiProperties)
        Creates an EJB3 rule session factory, saving initial JNDI context creation properties. These properties are later used by the factory methods to lookup rule session bean references.
        Parameters:
        jndiProperties - properties used to create the initial JNDI context. If null, no properties will be used.
    • Method Detail

      • createStatefulSession

        public IlrStatefulSession createStatefulSession(IlrPath rulesetPath,
                                               java.io.Serializable userData,
                                               java.util.Map<java.lang.String,java.lang.Object> initParameters,
                                               boolean forceUptodate)
                                                 throws IlrSessionCreationException
        Finds a reference to an initialized stateful EJB3 rule session bean.
        Specified by:
        createStatefulSession in interface IlrSessionFactory
        Overrides:
        createStatefulSession in class ilog.rules.res.session.impl.IlrSessionFactoryBase
        Throws:
        IlrSessionCreationException - if an error occurred while searching for the Bean.
        Parameters:
        rulesetPath - The ruleset path for the session.
        userData - A serializable object supplied by the user.
        initParameters - Initialization parameters used by the interceptors if necessary.
        forceUptodate - Set to true to indicate that the latest version of the ruleset must be used.
        Returns:
        A reference to an initialized stateful EJB3 rule session bean from the JNDI namespace.
      • createStatefulSession

        public IlrStatefulSession createStatefulSession(IlrPath rulesetPath,
                                               java.io.Serializable userData,
                                               java.util.Map<java.lang.String,java.lang.Object> initParameters,
                                               boolean forceUptodate,
                                               boolean enableInterceptor)
                                                 throws IlrSessionCreationException
        Finds a reference to an initialized stateful EJB3 rule session bean.
        Throws:
        IlrSessionCreationException - if an error occurred while searching for the Bean.
        Parameters:
        rulesetPath - The ruleset path for the session.
        userData - A serializable object supplied by the user.
        initParameters - Initialization parameters used by the interceptors if necessary.
        forceUptodate - Set to true to indicate that the latest version of the ruleset must be used.
        enableInterceptor - Set to true to indicate that the interceptors should be enabled
        Returns:
        A reference to an initialized stateful EJB3 rule session bean from the JNDI namespace.
      • createManagementSession

        public IlrManagementSession createManagementSession()
                                                     throws IlrSessionCreationException
        Management sessions are not available when using the EJB packaging, this method always throws an UnsupportedOperationException.
        Throws:
        IlrSessionCreationException - is never thrown. This method always throws an UnsupportedOperationException.
        Returns:
        This method always throws UnsupportedOperationException
      • isRemote

        public boolean isRemote()
        Checks if remote EJBs are being used.
        Returns:
        When remote EJBs are being used, true is returned.
      • setRemote

        public void setRemote(boolean remote)
        Sets the remote flag for this rule session factory.
        Parameters:
        remote - Set to true to use remote beans.
      • getStatelessLocalJndiName

        public java.lang.String getStatelessLocalJndiName()
        Returns the JNDI name for the local stateless session.
        Returns:
        The JNDI name.
      • setStatelessLocalJndiName

        public void setStatelessLocalJndiName(java.lang.String statelessLocalJndiName)
        Sets JNDI name for the local stateless session.
        Parameters:
        statelessLocalJndiName - The JNDI name.
      • getStatelessRemoteJndiName

        public java.lang.String getStatelessRemoteJndiName()
        Returns the JNDI name for the remote stateless session.
        Returns:
        The JNDI name.
      • setStatelessRemoteJndiName

        public void setStatelessRemoteJndiName(java.lang.String statelessRemoteJndiName)
        Sets the JNDI name for the remote stateless session.
        Parameters:
        statelessRemoteJndiName - The JNDI name.
      • getStatefulLocalJndiName

        public java.lang.String getStatefulLocalJndiName()
        Returns the JNDI name for the local stateful session.
        Returns:
        The JNDI name.
      • setStatefulLocalJndiName

        public void setStatefulLocalJndiName(java.lang.String statefulLocalJndiName)
        Sets the JNDI name for the local stateful session.
        Parameters:
        statefulLocalJndiName - The JNDI name.
      • getStatefulRemoteJndiName

        public java.lang.String getStatefulRemoteJndiName()
        Returns JNDI name for the remote stateful session.
        Returns:
        Tne JNDI name.
      • setStatefulRemoteJndiName

        public void setStatefulRemoteJndiName(java.lang.String statefulRemoteJndiName)
        Sets the JNDI name for the remote stateful session.
        Parameters:
        statefulRemoteJndiName - The JNDI name.

© Copyright IBM Corp. 1987, 2015