new ( handler ) transport = Thrift :: ServerSocket. new () processor = Calculator :: Processor. unshift '././lib/rb/lib' require 'thrift' require 'calculator' require 'shared_types' class CalculatorHandler def initialize () = " = entry return val end def getStruct ( key ) print "getStruct(", key, ") \n " return end def zip () print "zip \n " end end handler = CalculatorHandler. This snippet was generated by Apache Thrift's source tree docs: close () rescue Thrift :: Exception => tx print 'Thrift::Exception: ', tx. calculate ( 1, work ) puts "Whoa, we can divide by 0 now?" rescue InvalidOperation => io print "InvalidOperation: ", io. calculate ( 1, work ) print "15-10=", diff, " \n " log = client. new ( transport ) client = Calculator :: Client. new ( 'localhost', port )) protocol = Thrift :: BinaryProtocol. unshift '././lib/rb/lib' require 'thrift' require 'calculator' begin port = ARGV || 9090 transport = Thrift :: BufferedTransport. For running scripts using cucumber and Ruby, we can use command line too, however while developing scripts RubyMine makes our lives so much easier.$. Tip: Most of them are really impressed with the editor that they end up paying a small license fee. The extractor would openĨ) Download and Install Ruby Mine Editor (Free Evaluation for 30 days)ĭownload the RubyMine-6.3.3.exe anywhere on your machine and double click and accept all defaults. belowĦ) Download and Extract Devkit ( Download the one underneath the text “For use with Ruby 2.0 and 2.1 (32bit version only)” )Ī) Double click the. exe file and accept the defaultsģ) Do not forget to click on “Add Ruby executables to your PATH”Ĥ) Generally installs to C:\Ruby200 for windows machinesĥ) Open a command prompt and verify that Ruby is installed. It is okay to install newer versions too like Ruby 2.1.3, however I have used 2.0.0Ģ) Double click the. 1) Download Ruby from this location (32 bit installer works with 64 bit machines too, so please go ahead and download Ruby 2.0.0-p575).
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |