lib/hornetq.rb in jruby-hornetq-0.3.3 vs lib/hornetq.rb in jruby-hornetq-0.4.0
- old
+ new
@@ -23,9 +23,14 @@
def self.netty_port(port)
port ||= DEFAULT_NETTY_PORT
return java.lang.Integer.new(port)
end
+ # Convert string into a HornetQ SimpleString
+ def self.as_simple_string(str)
+ str.is_a?(Java::org.hornetq.api.core::SimpleString) ? str : Java::org.hornetq.api.core::SimpleString.new(str.to_s)
+ end
+
end
require 'hornetq/server'
require 'hornetq/client'
require 'hornetq/uri'