るりまサーチ (Ruby 2.4.0)

最速Rubyリファレンスマニュアル検索!
4件ヒット [1-4件を表示] (0.065秒)

別のキーワード

  1. rss date=
  2. rss date
  3. date iso8601
  4. date rfc3339
  5. date jisx0301

ライブラリ

クラス

キーワード

検索結果

Date#<=>(other) -> -1 | 0 | 1 | nil (105556.0)

二つの日付を比較します。 同じ日付なら 0 を、self が other よりあとの日付なら 1 を、 その逆なら -1 を返します。

二つの日付を比較します。
同じ日付なら 0 を、self が other よりあとの日付なら 1 を、
その逆なら -1 を返します。

other は日付オブジェクトか、
天文学的なユリウス日をあらわす数値を指定します。
そうでない場合、比較ができないので nil を返します。

//emlist[][ruby]{
require "date"

p Date.new(2001, 2, 3) <=> Date.new(2001, 2, 4) # => -1
p Date.new(2001, 2, 3) <=> Date.new(2001, 2, 3) # => 0
p Date.new(20...

rss (523.0)

RSS を扱うためのライブラリです。

RSS を扱うためのライブラリです。

=== 参考

* RSS 0.91 http://backend.userland.com/rss091
* RSS 1.0 http://purl.org/rss/1.0/spec
* RSS 2.0 http://www.rssboard.org/rss-specification
* Atom 1.0 https://www.ietf.org/rfc/rfc4287.txt

=== 注意

RSS ParserはRSS 0.9x/1.0/2.0, Atom 1.0 をサポートしていますが,RSS 0.90
はサポートしてませ...

Range#cover?(obj) -> bool (235.0)

obj が範囲内に含まれている時に true を返します。

obj が範囲内に含まれている時に true を返します。

Range#include? と異なり <=> メソッドによる演算により範囲内かどうかを判定します。
Range#include? は原則として離散値を扱い、
Range#cover? は連続値を扱います。
(数値については、例外として Range#include? も連続的に扱います。)

Range#exclude_end?がfalseなら「begin <= obj <= end」を、
trueなら「begin <= obj < end」を意味します。

@param obj 比較対象のオブジェクトを指定します。

//eml...

Range.new(first, last, exclude_end = false) -> Range (91.0)

first から last までの範囲オブジェクトを生成して返しま す。

first から last までの範囲オブジェクトを生成して返しま
す。

exclude_end が真ならば終端を含まない範囲オブジェクトを生
成します。exclude_end 省略時には終端を含みます。

@param first 最初のオブジェクト
@param last 最後のオブジェクト
@param exclude_end 真をセットした場合終端を含まない範囲オブジェクトを生成します

@raise ArgumentError first <=> last が nil の場合に発生します

//emlist[例: 整数の範囲オブジェクトの場合][ruby]{
Range.new(...