Class Jt400Endpoint

  • All Implemented Interfaces:
    AutoCloseable, org.apache.camel.CamelContextAware, org.apache.camel.Endpoint, org.apache.camel.IsSingleton, org.apache.camel.MultipleConsumersSupport, org.apache.camel.Service, org.apache.camel.ShutdownableService, org.apache.camel.spi.HasId, org.apache.camel.StatefulService, org.apache.camel.SuspendableService

    @UriEndpoint(firstVersion="1.5.0",
                 scheme="jt400",
                 title="JT400",
                 syntax="jt400:userID:password@systemName/QSYS.LIB/objectPath.type",
                 category=MESSAGING,
                 headersClass=Jt400Constants.class)
    public class Jt400Endpoint
    extends org.apache.camel.support.ScheduledPollEndpoint
    implements org.apache.camel.MultipleConsumersSupport
    Exchanges messages with an IBM i system using data queues, message queues, or program call. IBM i is the replacement for AS/400 and iSeries servers.
    • Field Summary

      Fields 
      Modifier and Type Field Description
      static String KEY  
      static String SENDER_INFORMATION  
      • Fields inherited from class org.apache.camel.support.service.BaseService

        BUILT, FAILED, INITIALIZED, INITIALIZING, lock, NEW, SHUTDOWN, SHUTTING_DOWN, STARTED, STARTING, status, STOPPED, STOPPING, SUSPENDED, SUSPENDING
    • Constructor Summary

      Constructors 
      Modifier Constructor Description
      protected Jt400Endpoint​(String endpointUri, Jt400Component component)
      Creates a new IBM i data queue endpoint using a default connection pool provided by the component.
      protected Jt400Endpoint​(String endpointUri, Jt400Component component, com.ibm.as400.access.AS400ConnectionPool connectionPool)
      Creates a new IBM i data queue endpoint using the specified connection pool.
    • Constructor Detail

      • Jt400Endpoint

        protected Jt400Endpoint​(String endpointUri,
                                Jt400Component component)
                         throws org.apache.camel.CamelException
        Creates a new IBM i data queue endpoint using a default connection pool provided by the component.
        Throws:
        NullPointerException - if component is null
        org.apache.camel.CamelException
      • Jt400Endpoint

        protected Jt400Endpoint​(String endpointUri,
                                Jt400Component component,
                                com.ibm.as400.access.AS400ConnectionPool connectionPool)
                         throws org.apache.camel.CamelException
        Creates a new IBM i data queue endpoint using the specified connection pool.
        Throws:
        org.apache.camel.CamelException
    • Method Detail

      • createProducer

        public org.apache.camel.Producer createProducer()
                                                 throws Exception
        Specified by:
        createProducer in interface org.apache.camel.Endpoint
        Throws:
        Exception
      • createConsumer

        public org.apache.camel.Consumer createConsumer​(org.apache.camel.Processor processor)
                                                 throws Exception
        Specified by:
        createConsumer in interface org.apache.camel.Endpoint
        Throws:
        Exception
      • getSystem

        protected com.ibm.as400.access.AS400 getSystem()
        Obtains an AS400 object that connects to this endpoint. Since these objects represent limited resources, clients have the responsibility of releasing them when done.
        Returns:
        an AS400 object that connects to this endpoint
      • releaseSystem

        protected void releaseSystem​(com.ibm.as400.access.AS400 system)
        Releases a previously obtained AS400 object from use.
        Parameters:
        system - a previously obtained AS400 object
      • getObjectPath

        protected String getObjectPath()
        Returns the fully qualified integrated file system path name of the data queue of this endpoint.
        Returns:
        the fully qualified integrated file system path name of the data queue of this endpoint
      • setType

        public void setType​(Jt400Type type)
      • getSearchKey

        public String getSearchKey()
      • isKeyed

        public boolean isKeyed()
      • getOutputFieldsIdxArray

        public Integer[] getOutputFieldsIdxArray()
      • getCcsid

        public int getCcsid()
      • setOutputFieldsIdxArray

        public void setOutputFieldsIdxArray​(Integer[] outputFieldsIdxArray)
      • setSearchKey

        public void setSearchKey​(String searchKey)
      • setOutputFieldsIdx

        public void setOutputFieldsIdx​(String outputFieldsIdx)
      • setKeyed

        public void setKeyed​(boolean keyed)
      • getOutputFieldsLengthArray

        public Integer[] getOutputFieldsLengthArray()
      • isGuiAvailable

        public boolean isGuiAvailable()
      • setFieldsLength

        public void setFieldsLength​(String fieldsLength)
      • setOutputFieldsLengthArray

        public void setOutputFieldsLengthArray​(Integer[] outputFieldsLengthArray)
      • getCssid

        public int getCssid()
      • getUserID

        public String getUserID()
      • setCcsid

        public void setCcsid​(int ccsid)
      • setGuiAvailable

        public void setGuiAvailable​(boolean guiAvailable)
      • getPassword

        public String getPassword()
      • getSystemName

        public String getSystemName()
      • isFieldIdxForOuput

        public boolean isFieldIdxForOuput​(int idx)
      • getOutputFieldLength

        public int getOutputFieldLength​(int idx)
      • setObjectPath

        public void setObjectPath​(String objectPath)
      • setPassword

        public void setPassword​(String password)
      • setUserID

        public void setUserID​(String userID)
      • setSystemName

        public void setSystemName​(String systemName)
      • setSecured

        public void setSecured​(boolean secured)
      • isSecured

        public boolean isSecured()
      • getReadTimeout

        public int getReadTimeout()
      • setReadTimeout

        public void setReadTimeout​(int readTimeout)
      • setProcedureName

        public void setProcedureName​(String procedureName)
      • getProcedureName

        public String getProcedureName()
      • setSendingReply

        public void setSendingReply​(boolean sendingReply)
      • isSendingReply

        public boolean isSendingReply()
      • isMultipleConsumersSupported

        public boolean isMultipleConsumersSupported()
        Specified by:
        isMultipleConsumersSupported in interface org.apache.camel.MultipleConsumersSupport