⚝
One Hat Cyber Team
⚝
Your IP:
216.73.216.93
Server IP:
65.108.141.171
Server:
Linux server.heloix.com 5.4.0-214-generic #234-Ubuntu SMP Fri Mar 14 23:50:27 UTC 2025 x86_64
Server Software:
Apache
PHP Version:
7.4.33
Buat File
|
Buat Folder
Eksekusi
Dir :
~
/
usr
/
share
/
ri
/
2.7.0
/
system
/
RSS
/
Utils
/
View File Name :
get_file_and_line_from_caller-i.ri
U:RDoc::AnyMethod[iI""get_file_and_line_from_caller:ETI"-RSS::Utils#get_file_and_line_from_caller;TF:publico:RDoc::Markup::Document:@parts[o:RDoc::Markup::Paragraph; [I"MReturns an array of two elements: the filename where the calling method ;TI"9is located, and the line number where it is defined.;To:RDoc::Markup::BlankLine o; ; [I"MTakes an optional argument +i+, which specifies how many callers up the ;TI"stack to look.;T@o; ; [I"Examples:;T@o:RDoc::Markup::Verbatim; [I"require 'rss/utils' ;TI" ;TI" def foo ;TI"2 p RSS::Utils.get_file_and_line_from_caller ;TI"5 p RSS::Utils.get_file_and_line_from_caller(1) ;TI" end ;TI" ;TI" def bar ;TI" foo ;TI" end ;TI" ;TI" def baz ;TI" bar ;TI" end ;TI" ;TI" baz ;TI"# => ["test.rb", 5] ;TI"# => ["test.rb", 9] ;T:@format0o; ; [I"NIf +i+ is not given, or is the default value of 0, it attempts to figure ;TI"Dout the correct value. This is useful when in combination with ;TI" instance_eval. For example:;T@o;; [I"require 'rss/utils' ;TI" ;TI" def foo ;TI"5 p RSS::Utils.get_file_and_line_from_caller(1) ;TI" end ;TI" ;TI" def bar ;TI" foo ;TI" end ;TI" ;TI"Finstance_eval <<-RUBY, *RSS::Utils.get_file_and_line_from_caller ;TI" def baz ;TI" bar ;TI" end ;TI" RUBY ;TI" ;TI" baz ;TI" ;TI"# => ["test.rb", 8];T; 0: @fileI"lib/rss/utils.rb;T:0@omit_headings_from_table_of_contents_below000[ I" (i=0);T@EFI" Utils;TcRDoc::NormalModule00