種類
- インスタンスメソッド (23)
- 文書 (22)
- 定数 (22)
- 特異メソッド (17)
クラス
- CGI (11)
- CSV (11)
- File (11)
- OptionParser (11)
- Shell (12)
-
Shell
:: Filter (6)
キーワード
-
PATH
_ SEPARATOR (22) -
default
_ record _ separator (6) - each (6)
- new (11)
-
record
_ separator (6) -
ruby 1
. 6 feature (11) - 正規表現 (11)
検索結果
先頭5件
-
OptionParser
# separator(sep) -> () (21131.0) -
サマリにオプションを区切るための文字列 sep を挿入します。 オプションにいくつかの種類がある場合に、サマリがわかりやすくなります。
...list[][ruby]{
require 'optparse'
opts = OptionParser.new
opts.banner = "Usage: example.rb [options]"
opts.separator ""
opts.separator "Specific options:"
opts.on("-r", "--require LIBRARY") do |lib|
options.library << lib
end
opts.separator ""
opts.separator "Common options:"
opts.on_tail......("-h", "--help", "Show this message") do
puts opts
exit
end
//}... -
CGI
:: PATH _ SEPARATOR -> Hash (15201.0) -
パスの区切り文字を格納します。
パスの区切り文字を格納します。 -
File
:: PATH _ SEPARATOR -> ";" | ":" (15201.0) -
PATH 環境変数の要素のセパレータです。UNIX では ":" MS-DOS な どでは ";" です。
...PATH 環境変数の要素のセパレータです。UNIX では ":" MS-DOS な
どでは ";" です。... -
Shell
:: Filter # each(rs = nil) -> () (9206.0) -
フィルタの一行ずつをblockに渡します。
...行ずつをblockに渡します。
@param rs レコードセパレーターを表す文字列を指定します。
nil ならば、Shell.record_separatorの値が使用されます。
使用例
require 'shell'
sh = Shell.new
sh.cat("/etc/passwd").each { |line|
puts line
}... -
Shell
. default _ record _ separator -> String (9202.0) -
執筆者募集
...執筆者募集
Shell で用いられる入力レコードセパレータを表す文字列を設定および参照します。
なにも指定しない場合は$/ の値が用いられます。
@param rs Shell で用いられる入力レコードセパレータを表す文字列を指定しま... -
Shell
# record _ separator -> String (9201.0) -
@todo
@todo -
ruby 1
. 6 feature (1152.0) -
ruby 1.6 feature ruby version 1.6 は安定版です。この版での変更はバグ修正がメイン になります。
...by version 1.6 は安定版です。この版での変更はバグ修正がメイン
になります。
((<stable-snapshot|URL:ftp://ftp.netlab.co.jp/pub/lang/ruby/stable-snapshot.tar.gz>)) は、日々更新される安定版の最新ソースです。
== 1.6.8 (2002-12-24) -> stable-snapshot
:......EAGAIN と EWOULDBLOCK が同じ値のシステムで、EWOULDBLOCK がなくなっ
ていました。現在は、このようなシステムでは、EWOULDBLOCK は、EAGAIN
として定義されています。(これは 1.6.7 とは異なる挙動です)
p Errno::EAGAIN......に nil を指定できるようになりました。((<ruby-talk:43513>))
この場合、$; を分割文字列として使用します。以前までは $; が有効にな
るのは引数省略時だけでした。
$; = ":"
p "a:b:c".split(nil)
=> -:2:in `split': bad separator (Ar... -
CSV
. new(data , options = Hash . new) -> CSV (206.0) -
このメソッドは CSV ファイルを読み込んだり、書き出したりするために String か IO のインスタンスをラップします。
...このメソッドは CSV ファイルを読み込んだり、書き出したりするために
String か IO のインスタンスをラップします。
ラップされた文字列の先頭から読み込むことになります。
文字列に追記したい場合は CSV.generate を使用し......equence will be selected even if it occurs in a quoted field, assuming that you
would have the same line endings there. If none of those sequences is
found, +data+ is ARGF, Object::STDIN, Object::STDOUT, or
Object::STDERR, or the stream is only available for output, the default
$INPUT_RECO......) is used. Obviously,
discovery takes a little time. Set manually if speed is important. Also
note that IO objects should be opened in binary mode on Windows if this
feature will be used as the line-ending translation can cause
problems with resetting the document position to where it... -
正規表現 (162.0)
-
正規表現 * metachar * expansion * char * anychar * string * str * quantifier * capture * grouping * subexp * selector * anchor * cond * option * encoding * comment * free_format_mode * absenceop * list * specialvar * references
...* metachar
* expansion
* char
* anychar
* string
* str
* quantifier
* capture
* grouping
* subexp
* selector
* anchor
* cond
* option
* encoding
* comment
* free_format_mode
* absenceop
* list
* specialvar
* references
正規表現(regular expression)は......どの場所であるかを知ることができます。
//emlist[][ruby]{
/pat/
%r{pat}
//}
などの正規表現リテラルや Regexp.new などで正規表現
オブジェクトを得ることができます。
===[a:metachar] メタ文字列とリテラル、メタ文字とエスケープ......かが Unicode プロパティや
Unicode コードポイントで示されています。
* [:alnum:] 英数字 (Letter | Mark | Decimal_Number)
* [:alpha:] 英字 (Letter | Mark)
* [:ascii:] ASCIIに含まれる文字 (0000 - 007F)
* [:blank:] スペースとタブ (Space_Separator | 0009)...