Sha256: 8b2e0f37c06c25aecd19992321772199d2d7c3a612d27fd7a6cc0e659318f4d4
Contents?: true
Size: 624 Bytes
Versions: 1
Compression:
Stored size: 624 Bytes
Contents
# 日付を扱うクラス Date に機能を追加するモジュール module PositiveTimeSupport::DateExt WDAYS_JA_SHORT = [ "日" , "月" , "火" , "水" , "木" , "金" , "土" ] def wday_ja_short WDAYS_JA_SHORT[ wday ] end def wday_ja "#{ wday_ja_short }曜" end alias :wday_ja_normal :wday_ja def wday_ja_long "#{ wday_ja_short }曜日" end # (日本の)祝日か否かを判定するメソッド # @return [Boolean] def holiday? ::HolidayJapan.check( ::Date.new( year , month , day ) ) end def to_strf_date_ja "#{ year }年#{ month }月#{ day }日" end end
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
positive_time_support-0.2.0 | lib/positive_time_support/date_ext.rb |