TAILIEUCHUNG - HandBooks Professional Java-C-Scrip-SQL part 232

Tham khảo tài liệu 'handbooks professional java-c-scrip-sql part 232', công nghệ thông tin, kỹ thuật lập trình phục vụ nhu cầu học tập, nghiên cứu và làm việc hiệu quả | Ruby in a Nutshell By Yukihiro Matsumoto Chapter 3. Built-in Library Reference Built-in Functions Since the Kernel module is included by Obj ect class its methods are available everywhere in the Ruby program. They can be called without a receiver functional form therefore they are often called functions. abort Terminates program. If an exception is raised . isn t nil its error message is displayed. Array obj Returns obj after converting it to an array using to_ary or to_a. at_exit . Registers a block for execution when the program exits. Similar to END statement referenced in binding Returns the current variable and method bindings. The Binding object that is returned may be passed to the eval method as its second argument. block_given Returns true if the method was called with a block. callcc c . Passes a Continuation object c to the block and executes the block. callcc can be used for global exit or loop construct. def foo c puts in foo jump out puts out foo this line never be executed end callcc c foo c prints in foo caller n Returns the current execution stack in an array of the strings in the form file line. If n is specified returns stack entries from nth level on down. catch tag . Catches a nonlocal exit by a throw called during the execution of its block. def throwing n throw exit n 2 end catch exit puts before throwing throwing 5 puts after throwing this line never be executed returns 7 chomp rs Returns the value of variable _ with the ending newline removed assigning the result back to _. The value of the newline string can be specified with rs. _ foo n chomp _ foo _ foo chomp no chomp chomp rs Removes newline from _ modifying the string in place. chop Returns the value of _ with its last character one byte removed assigning the result back to _. _ foo n chop _ foo _ foo chop _ fo chop Removes the last character from _ modifying the string in place. eval str scope _ file line Executes str as Ruby code. The binding in which to perform the .

TAILIEUCHUNG - Chia sẻ tài liệu không giới hạn
Địa chỉ : 444 Hoang Hoa Tham, Hanoi, Viet Nam
Website : tailieuchung.com
Email : tailieuchung20@gmail.com
Tailieuchung.com là thư viện tài liệu trực tuyến, nơi chia sẽ trao đổi hàng triệu tài liệu như luận văn đồ án, sách, giáo trình, đề thi.
Chúng tôi không chịu trách nhiệm liên quan đến các vấn đề bản quyền nội dung tài liệu được thành viên tự nguyện đăng tải lên, nếu phát hiện thấy tài liệu xấu hoặc tài liệu có bản quyền xin hãy email cho chúng tôi.
Đã phát hiện trình chặn quảng cáo AdBlock
Trang web này phụ thuộc vào doanh thu từ số lần hiển thị quảng cáo để tồn tại. Vui lòng tắt trình chặn quảng cáo của bạn hoặc tạm dừng tính năng chặn quảng cáo cho trang web này.