るりまサーチ

最速Rubyリファレンスマニュアル検索!
33件ヒット [1-33件を表示] (0.102秒)
トップページ > クエリ:l[x] > クエリ:require[x] > クエリ:exist?[x]

別のキーワード

  1. kernel require
  2. getoptlong require_order
  3. rubygems/custom_require require
  4. irb/ext/use-loader irb_require
  5. require execute

ライブラリ

クラス

キーワード

検索結果

StringScanner#exist?(regexp) -> Integer | nil (18206.0)

スキャンポインタの位置から,次にマッチする文字列の末尾までの長さを返します。

...nil を返します。

このメソッドはマッチが成功してもスキャンポインタを進めません。

@param regexp マッチに用いる正規表現を指定します。

//emlist[例][ruby]{
require
'strscan'

s = StringScanner.new('test string')
s.exist?(/s/) # => 3
s.exist?(//)...
...# => 0
s.scan(/\w+/) # => "test"
s.exist?(/s/) # => 2
s.exist?(/e/) # => nil
//}...

Pathname#delete -> Integer (6118.0)

self が指すディレクトリあるいはファイルを削除します。

...self が指すディレクトリあるいはファイルを削除します。

//emlist[例][ruby]{
require
"pathname"

pathname = Pathname("/path/to/sample")
pathname.exist? # => true
pathname.unlink # => 1
pathname.exist? # => false
//}...

Pathname#unlink -> Integer (6118.0)

self が指すディレクトリあるいはファイルを削除します。

...self が指すディレクトリあるいはファイルを削除します。

//emlist[例][ruby]{
require
"pathname"

pathname = Pathname("/path/to/sample")
pathname.exist? # => true
pathname.unlink # => 1
pathname.exist? # => false
//}...