Class: ThriftHelpers::Connection::Factory
- Inherits:
-
Object
- Object
- ThriftHelpers::Connection::Factory
- Defined in:
- lib/thrift_client/connection/factory.rb
Class Method Summary collapse
Class Method Details
.create(transport, transport_wrapper, server, timeout) ⇒ Object
4 5 6 7 8 9 10 |
# File 'lib/thrift_client/connection/factory.rb', line 4 def self.create(transport, transport_wrapper, server, timeout) if transport == Thrift::HTTPClientTransport Connection::HTTP.new(transport, transport_wrapper, server, timeout) else Connection::Socket.new(transport, transport_wrapper, server, timeout) end end |