Sha256: fa287f745265bfdab8ee106d0c93a6985d68bb47efacf02f97759c492e73c503

Contents?: true

Size: 253 Bytes

Versions: 3

Compression:

Stored size: 253 Bytes

Contents

# Extend Integer for use in our Daterange class
class Integer
  # Julian date number to Ruby Date
  def jd_to_date
    Date.jd(self)
  end

  def jd_to_datetime
    date = jd_to_date
    Ourdate.build_datetime(date.year, date.month, date.day)
  end
end

Version data entries

3 entries across 3 versions & 1 rubygems

Version Path
ndr_support-5.8.2 lib/ndr_support/integer/julian_date_conversions.rb
ndr_support-5.8.1 lib/ndr_support/integer/julian_date_conversions.rb
ndr_support-5.8.0 lib/ndr_support/integer/julian_date_conversions.rb