⚝
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
/
Module
/
View File Name :
const_get-i.ri
U:RDoc::AnyMethod[iI"const_get:ETI"Module#const_get;TF:publico:RDoc::Markup::Document:@parts[o:RDoc::Markup::Paragraph; [I">Checks for a constant with the given name in <i>mod</i>. ;TI"6If +inherit+ is set, the lookup will also search ;TI">the ancestors (and +Object+ if <i>mod</i> is a +Module+).;To:RDoc::Markup::BlankLine o; ; [I"EThe value of the constant is returned if a definition is found, ;TI"'otherwise a +NameError+ is raised.;T@o:RDoc::Markup::Verbatim; [I"0Math.const_get(:PI) #=> 3.14159265358979 ;T:@format0o; ; [I"IThis method will recursively look up constant names if a namespaced ;TI"*class name is provided. For example:;T@o;; [I"$module Foo; class Bar; end end ;TI"!Object.const_get 'Foo::Bar' ;T; 0o; ; [I"BThe +inherit+ flag is respected on each lookup. For example:;T@o;; [I"module Foo ;TI" class Bar ;TI" VAL = 10 ;TI" end ;TI" ;TI" class Baz < Bar; end ;TI" end ;TI" ;TI"6Object.const_get 'Foo::Baz::VAL' # => 10 ;TI"=Object.const_get 'Foo::Baz::VAL', false # => NameError ;T; 0o; ; [I"HIf the argument is not a valid constant name a +NameError+ will be ;TI"1raised with a warning "wrong constant name".;T@o;; [I"HObject.const_get 'foobar' #=> NameError: wrong constant name foobar;T; 0: @fileI" object.c;T:0@omit_headings_from_table_of_contents_below0I"[mod.const_get(sym, inherit=true) -> obj mod.const_get(str, inherit=true) -> obj ;T0[ I"(*args);T@6FI"Module;TcRDoc::NormalClass00