るりまサーチ

最速Rubyリファレンスマニュアル検索!
36件ヒット [1-36件を表示] (0.009秒)
トップページ > クエリ:sample[x] > クラス:Pathname[x]

別のキーワード

  1. array sample
  2. _builtin sample
  3. sample array
  4. sample random

ライブラリ

キーワード

検索結果

Pathname#split -> Array (13.0)

File.split(self.to_s) と同じです。

...File.split(self.to_s) と同じです。

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

pathname
= Pathname("/path/to/sample")
pathname
.split # => [#<Pathname:/path/to>, #<Pathname:sample>]
//}

@see File.split...

Pathname#delete -> Integer (7.0)

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

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

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

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

Pathname#unlink -> Integer (7.0)

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

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

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

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