ライブラリ
- ビルトイン (22)
- openssl (11)
-
rdoc
/ code _ object (11) - uri (11)
- win32ole (22)
クラス
-
RDoc
:: CodeObject (11) - Regexp (22)
-
URI
:: FTP (11) - WIN32OLE (11)
モジュール
-
OpenSSL
:: ASN1 (11)
キーワード
-
NEWS for Ruby 3
. 0 . 0 (4) -
NEWS for Ruby 3
. 1 . 0 (3) - Ruby用語集 (11)
- WIN32OLE (11)
- compile (11)
- decode (11)
- drb (11)
- locale= (11)
- new2 (11)
- rake (11)
-
rdoc
/ generator / json _ index (11) -
rexml
/ document (11) -
test
/ unit (1) - xmlrpc (3)
検索結果
先頭5件
-
NEWS for Ruby 3
. 0 . 0 (26126.0) -
NEWS for Ruby 3.0.0 このドキュメントは前回リリース以降のバグ修正を除くユーザーに影響のある機能の変更のリストです。
...NEWS for Ruby 3.0.0
このドキュメントは前回リリース以降のバグ修正を除くユーザーに影響のある機能の変更のリストです。
それぞれのエントリーは参照情報があるため短いです。
十分な情報と共に書かれた全ての変更のリス......トはリンク先を参照してください。
== 言語仕様の変更
* Keyword arguments are now separated from positional arguments.
Code that resulted in deprecation warnings in Ruby 2.7 will now
result in ArgumentError or different behavior. 14183
* Procs accepting a single res......shown by default (since Ruby 2.7.2).
Turn them on with `-W:deprecated` (or with `-w` to show other warnings too).
16345
* `$SAFE` and `$KCODE` are now normal global variables with no special behavior.
C-API methods related to `$SAFE` have been removed.
16131 17136
* yield in sin... -
NEWS for Ruby 3
. 1 . 0 (26048.0) -
NEWS for Ruby 3.1.0 このドキュメントは前回リリース以降のバグ修正を除くユーザーに影響のある機能の変更のリストです。
...NEWS for Ruby 3.1.0
このドキュメントは前回リリース以降のバグ修正を除くユーザーに影響のある機能の変更のリストです。
それぞれのエントリーは参照情報があるため短いです。
十分な情報と共に書かれた全ての変更のリス......た。ハッシュを最初のメンバにするには、ハッシュリテラルを使用する必要があります。 16806
* String
* Unicodeと絵文字のバージョンが13.0.0に更新されました。 17750 18029
* String#unpack と String#unpack1 が任意のバイト数をス......* Thread::Queue
* 変更されたメソッド
* Thread::Queue.new が、初期値のEnumerableオブジェクトを渡せるようになりました。 17327
* Time
* 変更されたメソッド
* Time.new は、Time.at や Time.now と同じようにタイムゾーンの in:... -
RDoc
:: CodeObject . new -> RDoc :: CodeObject (21201.0) -
自身を初期化します。
自身を初期化します。 -
Regexp
. new(string , option = nil , code = nil) -> Regexp (15209.0) -
文字列 string をコンパイルして正規表現オブジェクトを生成して返します。
...して見なされ
、真(nil, false 以外)であれば
Regexp::IGNORECASE の指定と同じになります。
@param code "n", "N" が与えられた時には、生成された正規表現のエンコーディングは ASCII-8BIT になります。
それ... -
URI
:: FTP . new2(user , password , host , port , path , typecode = nil , arg _ check = true) -> URI :: FTP (6201.0) -
URI::FTP オブジェクトを生成して返します。 引数の正当性を検査します。
...am typecode 構成要素を表す文字列を与えます。
@param arg_check 真が与えられた場合は、各引数が字句規則に適合しているか否かを検査します。適合しない場合は例外 URI::InvalidComponentError が起ります。
@raise ArgumentError typecode が... -
OpenSSL
:: ASN1 . # decode(der) -> OpenSSL :: ASN1 :: ASN1Data (6106.0) -
DER 表現の文字列を解析し、そこにエンコードされている ASN.1 の値を OpenSSL::ASN1::ASN1Data のサブクラスのインスタンスとして返します。
...析します。
例:
ruby -e '
require "openssl"
require "pp"
pem = File.read(ARGV[0])
cert = OpenSSL::X509::Certificate.new(pem)
pp OpenSSL::ASN1.decode(cert.to_der)
' mycert.pem
#<OpenSSL::ASN1::Sequence:0x814e9fc
@tag=16,
@tag_class=:UNIVERSAL,
@tagging=nil,
@value=... -
Regexp
. compile(string , option = nil , code = nil) -> Regexp (109.0) -
文字列 string をコンパイルして正規表現オブジェクトを生成して返します。
...して見なされ
、真(nil, false 以外)であれば
Regexp::IGNORECASE の指定と同じになります。
@param code "n", "N" が与えられた時には、生成された正規表現のエンコーディングは ASCII-8BIT になります。
それ... -
xmlrpc (54.0)
-
XML-RPC を扱うためのライブラリです。
...res and a client that calls them. Very little code
is required to achieve either of these.
=== Example
Try the following code. It calls a standard demonstration remote procedure.
require 'xmlrpc/client'
require 'pp'
server = XMLRPC::Client.new2("http://xmlrpc-c.sourceforge.net/api/sample......server = XMLRPC::Client.new( "xmlrpc-c.sourceforge.net", "/api/sample.php")
server.set_parser(XMLRPC::XMLParser::XMLParser.new)
# ...
Server Example:
require 'xmlrpc/server'
# ...
s = XMLRPC::CGIServer.new
s.set_parser(XMLRPC::XMLParser::XMLStreamParser.new)
# ...
or:
requir......e 'xmlrpc/server'
# ...
server = XMLRPC::Server.new(8080)
server.set_parser(XMLRPC::XMLParser::NQXMLParser.new)
# ...
Note that XMLStreamParser is incredible faster (and uses less memory) than any
other parser and scales well for large documents. For example for a 0.5 MB XML
document with... -
rexml
/ document (36.0) -
DOM スタイルの XML パーサ。
...DOM スタイルの XML パーサ。
REXML::Document.new で XML 文書から DOM ツリーを
構築し、ツリーのノードの各メソッドで文書の内容にアクセスします。
以下のプログラムではブックマークの XML からデータを取り出します。
//emlist[......][ruby]{
require 'rexml/document'
require 'pp'
Bookmark = Struct.new(:href, :title, :desc)
doc = REXML::Document.new(<<XML)
<?xml version="1.0" encoding="UTF-8" ?>
<xbel version="1.0">
<bookmark href="http://www.ruby-lang.org/ja/">
<title>オブジェクト指向スクリプト言語 Ruby</t......itle>
<desc>Rubyの公式サイト</desc>
</bookmark>
<bookmark href="http://rurema.clear-code.com/">
<title>最速Rubyリファレンスマニュアル検索! | るりまサーチ</title>
<desc>Rubyリファレンスマニュアルを全文検索できる。
とても便利。... -
WIN32OLE (24.0)
-
OLEオートメーションサーバをRubyで操作するためのクラスです。
...数としてキーにパラメータ名、値に引数を指定できます。
=== サンプルコード
require 'win32ole'
excel = WIN32OLE.new('Excel.Application')
workbook = excel.Workbooks.Open('workbook.xls')
workbook.PrintOut
workbook.Close(:SaveChanges => false)
excel.Quit
な......にOLEオートメーションサーバのメソッド名は小文
字で記述しても構いません。
require 'win32ole'
excel = WIN32OLE.new('Excel.Application')
workbook = excel.workbooks.open('workbook.xls')
workbook.printout
workbook.close(:SaveChanges => false)
excel.quit
=......スレッドをまたがる呼び出しはエラーとなります。
excel = WIN32OLE.new('Excel.Application')
Thread.start do
workbook = excel.Workbooks.Open('workbook.xls') #=> HRESULT error code:0x800401f0
workbook.PrintOut
workbook.Close(:SaveChanges => false)
end.join
exce... -
drb (24.0)
-
分散オブジェクトプログラミングのためのライブラリです。
...ro = DRbObject.new_with_uri("druby://your.server.com:8989")
class << ro
# リモートオブジェクトの instance_eval を呼ぶため
# ローカルオブジェクトの instance_eval を取り除く
undef :instance_eval
end
ro.instance_eval("DANGEROUS RUBY CODE!")
このよ......rent_time
return Time.now
end
end
# サーバ側でリクエストを受け付けるオブジェクト
FRONT_OBJECT=TimeServer.new
# サーバを起動する
DRb.start_service(SERVER_URI, FRONT_OBJECT, :safe_level => 1)
# DRb のスレッドが終了するのを待つ......ブジェクト以外の
# リモートオブジェクトのメソッドを呼び出す時には必要
DRb.start_service
# リモートオブジェクトの取得
timeserver = DRbObject.new_with_uri(SERVER_URI)
# リモートメソッドの呼び出し
puts timeserver.get_current_time... -
rake (24.0)
-
Rake というコマンドラインツールを扱うライブラリです。
...クを実行します。
-e, --execute CODE Ruby のコードを実行して終了します。
-p, --execute-print CODE Ruby のコードを実行して結果を表示して終了します。
-E, --execute-continue CODE Ruby のコードを実行してから、タ......ttask'
require 'rake/clean' # clean, clobber の二つのタスクを定義
task :default => [:test]
1.upto(8) do |n|
Rake::TestTask.new("test_step#{n}") do |t|
t.libs << "step#{n}"
t.test_files = FileList["step#{n}/test_*.rb"]
t.verbose = false
end
end
d...