Gestionnaire de fichiers - Editer - /opt/cpanel/ea-ruby24/root/usr/share/ri/system/SDBM/cdesc-SDBM.ri
Arrière
U:RDoc::NormalClass[iI" SDBM:ET@I"Object;To:RDoc::Markup::Document:@parts[o;;[o:RDoc::Markup::Paragraph;[I"MSDBM provides a simple file-based key-value store, which can only store ;TI"String keys and values.;To:RDoc::Markup::BlankLine o; ;[I"PNote that Ruby comes with the source code for SDBM, while the DBM and GDBM ;TI"?standard libraries rely on external libraries and headers.;T@S:RDoc::Markup::Heading: leveli: textI" Examples;T@o; ;[I"Insert values:;T@o:RDoc::Markup::Verbatim;[ I"require 'sdbm' ;TI" ;TI"%SDBM.open 'my_database' do |db| ;TI" db['apple'] = 'fruit' ;TI" db['pear'] = 'fruit' ;TI"" db['carrot'] = 'vegetable' ;TI"" db['tomato'] = 'vegetable' ;TI" end ;T:@format0o; ;[I"Bulk update:;T@o;;[ I"require 'sdbm' ;TI" ;TI"%SDBM.open 'my_database' do |db| ;TI": db.update('peach' => 'fruit', 'tomato' => 'fruit') ;TI" end ;T;0o; ;[I"Retrieve values:;T@o;;[I"require 'sdbm' ;TI" ;TI"%SDBM.open 'my_database' do |db| ;TI" db.each do |key, value| ;TI"- puts "Key: #{key}, Value: #{value}" ;TI" end ;TI" end ;T;0o; ;[I" Outputs:;T@o;;[ I"Key: apple, Value: fruit ;TI"Key: pear, Value: fruit ;TI"#Key: carrot, Value: vegetable ;TI"Key: peach, Value: fruit ;TI"Key: tomato, Value: fruit;T;0: @fileI"ext/sdbm/init.c;T:0@omit_headings_from_table_of_contents_below0;0;0[ [ [[I"Enumerable;To;;[ ;@E;0I"ext/sdbm/init.c;T[[I" class;T[[:public[[I"new;T@M[I" open;T@M[:protected[ [:private[ [I" instance;T[[;[([I"[];T@M[I"[]=;T@M[I" clear;T@M[I" close;T@M[I"closed?;T@M[I"delete;T@M[I"delete_if;T@M[I" each;T@M[I" each_key;T@M[I"each_pair;T@M[I"each_value;T@M[I"empty?;T@M[I" fetch;T@M[I" has_key?;T@M[I"has_value?;T@M[I" include?;T@M[I"invert;T@M[I"key;T@M[I" key?;T@M[I" keys;T@M[I"length;T@M[I"member?;T@M[I"reject;T@M[I"reject!;T@M[I"replace;T@M[I"select;T@M[I" shift;T@M[I" size;T@M[I" store;T@M[I" to_a;T@M[I"to_hash;T@M[I"update;T@M[I"value?;T@M[I"values;T@M[I"values_at;T@M[;[ [;[ [ [U:RDoc::Context::Section[i 0o;;[ ;0;0[@E@EcRDoc::TopLevel
| ver. 1.4 |
Github
|
.
| PHP 8.0.30 | Génération de la page: 0.01 |
proxy
|
phpinfo
|
Réglages