Class: JMS::OracleAQConnectionFactory
- Inherits:
-
Object
- Object
- JMS::OracleAQConnectionFactory
- Defined in:
- lib/jms/oracle_a_q_connection_factory.rb
Overview
Connection Factory to support Oracle AQ
Instance Attribute Summary collapse
-
#password ⇒ Object
writeonly
Sets the attribute password.
-
#url ⇒ Object
Returns the value of attribute url.
-
#username ⇒ Object
Returns the value of attribute username.
Instance Method Summary collapse
-
#create_connection ⇒ Object
Creates a connection per standard JMS 1.1 techniques from the Oracle AQ JMS Interface.
Instance Attribute Details
#password=(value) ⇒ Object (writeonly)
Sets the attribute password
22 23 24 |
# File 'lib/jms/oracle_a_q_connection_factory.rb', line 22 def password=(value) @password = value end |
#url ⇒ Object
Returns the value of attribute url.
21 22 23 |
# File 'lib/jms/oracle_a_q_connection_factory.rb', line 21 def url @url end |
#username ⇒ Object
Returns the value of attribute username.
21 22 23 |
# File 'lib/jms/oracle_a_q_connection_factory.rb', line 21 def username @username end |
Instance Method Details
#create_connection ⇒ Object
Creates a connection per standard JMS 1.1 techniques from the Oracle AQ JMS Interface
25 26 27 28 29 30 31 32 |
# File 'lib/jms/oracle_a_q_connection_factory.rb', line 25 def create_connection cf = oracle.jms.AQjmsFactory.getConnectionFactory(@url, java.util.Properties.new) if username cf.createConnection(@username, @password) else cf.createConnection() end end |