开发者

File.file?() and File::directory?()

开发者 https://www.devze.com 2023-02-06 23:39 出处:网络
Newbie question here, but in Ruby, why would File.file?() and File::directory?开发者_开发问答() be called differently?File::file? and File.file? are equivalent, as are File::directory? and File.direct

Newbie question here, but in Ruby, why would File.file?() and File::directory?开发者_开发问答() be called differently?


File::file? and File.file? are equivalent, as are File::directory? and File.directory?. Both are methods belonging to the class, and may be invoked with either syntax.

0

精彩评论

暂无评论...
验证码 换一张
取 消