⚝
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
/
Class
/
View File Name :
new-c.ri
U:RDoc::AnyMethod[iI"new:ETI"Class::new;TT:publico:RDoc::Markup::Document:@parts[o:RDoc::Markup::Paragraph; [I"GCreates a new anonymous (unnamed) class with the given superclass ;TI":(or Object if no parameter is given). You can give a ;TI">class a name by assigning the class object to a constant.;To:RDoc::Markup::BlankLine o; ; [I"GIf a block is given, it is passed the class object, and the block ;TI"4is evaluated in the context of this class like ;TI"#class_eval.;T@o:RDoc::Markup::Verbatim; [I"fred = Class.new do ;TI" def meth1 ;TI" "hello" ;TI" end ;TI" def meth2 ;TI" "bye" ;TI" end ;TI" end ;TI" ;TI">a = fred.new #=> #<#<Class:0x100381890>:0x100376b98> ;TI""a.meth1 #=> "hello" ;TI" a.meth2 #=> "bye" ;T:@format0o; ; [I"EAssign the class to a constant (name starting uppercase) if you ;TI"+want to treat it like a regular class.;T: @fileI" object.c;T:0@omit_headings_from_table_of_contents_below0I"sClass.new(super_class=Object) -> a_class Class.new(super_class=Object) { |mod| ... } -> a_class ;T0[ I"(*args);T@(FI" Class;TcRDoc::NormalClass00