Class: VertxStomp::DestinationFactory
- Inherits:
-
Object
- Object
- VertxStomp::DestinationFactory
show all
- Defined in:
- /Users/julien/java/vertx-aggregator/modules/vertx-lang-ruby/vertx-lang-ruby/target/classes/vertx-stomp/destination_factory.rb
Overview
Interface implemented to customize the destination creation.
Constant Summary
- @@j_api_type =
Object.new
Class Method Summary
(collapse)
Instance Method Summary
(collapse)
Class Method Details
+ (Boolean) accept?(obj)
20
21
22
|
# File '/Users/julien/java/vertx-aggregator/modules/vertx-lang-ruby/vertx-lang-ruby/target/classes/vertx-stomp/destination_factory.rb', line 20
def @@j_api_type.accept?(obj)
obj.class == DestinationFactory
end
|
+ (Object) j_api_type
29
30
31
|
# File '/Users/julien/java/vertx-aggregator/modules/vertx-lang-ruby/vertx-lang-ruby/target/classes/vertx-stomp/destination_factory.rb', line 29
def self.j_api_type
@@j_api_type
end
|
+ (Object) j_class
32
33
34
|
# File '/Users/julien/java/vertx-aggregator/modules/vertx-lang-ruby/vertx-lang-ruby/target/classes/vertx-stomp/destination_factory.rb', line 32
def self.j_class
Java::IoVertxExtStomp::DestinationFactory.java_class
end
|
+ (Object) unwrap(obj)
26
27
28
|
# File '/Users/julien/java/vertx-aggregator/modules/vertx-lang-ruby/vertx-lang-ruby/target/classes/vertx-stomp/destination_factory.rb', line 26
def @@j_api_type.unwrap(obj)
obj.j_del
end
|
+ (Object) wrap(obj)
23
24
25
|
# File '/Users/julien/java/vertx-aggregator/modules/vertx-lang-ruby/vertx-lang-ruby/target/classes/vertx-stomp/destination_factory.rb', line 23
def @@j_api_type.wrap(obj)
DestinationFactory.new(obj)
end
|
Instance Method Details
Creates a destination for the given address.
40
41
42
43
44
45
46
47
48
49
|
# File '/Users/julien/java/vertx-aggregator/modules/vertx-lang-ruby/vertx-lang-ruby/target/classes/vertx-stomp/destination_factory.rb', line 40
def create(*args)
if args[0].class.method_defined?(:j_del) && args[1].class == String && !block_given?
return ::Vertx::Util::Utils.safe_create(@j_del.java_method(:create, [Java::IoVertxCore::Vertx.java_class,Java::java.lang.String.java_class]).call(args[0].j_del,args[1]),::VertxStomp::Destination)
end
if defined?(super)
super
else
raise ArgumentError, "Invalid arguments when calling create(#{args[0]},#{args[1]})"
end
end
|