Module: Holidays::SE

Defined in:
lib/generated_definitions/se.rb

Overview

This file is generated by the Ruby Holidays gem.

Definitions loaded: definitions/se.yaml

To use the definitions in this file, load it right after you load the Holiday gem:

require 'holidays'
require 'generated_definitions/se'

All the definitions are available at github.com/holidays/holidays

Class Method Summary collapse

Class Method Details

.custom_methodsObject


41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
# File 'lib/generated_definitions/se.rb', line 41

def self.custom_methods
  {
    "se_midsommardagen(year)" => Proc.new { |year|
date = Date.civil(year,6,20)
date += (6 - date.wday)
date
},

"se_alla_helgons_dag(year)" => Proc.new { |year|
date = Date.civil(year,10,31)
date += (6 - date.wday)
date
},


  }
end

.defined_regionsObject


15
16
17
# File 'lib/generated_definitions/se.rb', line 15

def self.defined_regions
  [:se]
end

.holidays_by_monthObject


19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
# File 'lib/generated_definitions/se.rb', line 19

def self.holidays_by_month
  {
          0 => [{:function => "easter(year)", :function_arguments => [:year], :function_modifier => -2, :name => "Långfredagen", :regions => [:se]},
        {:function => "easter(year)", :function_arguments => [:year], :function_modifier => -1, :type => :informal, :name => "Påskafton", :regions => [:se]},
        {:function => "easter(year)", :function_arguments => [:year], :name => "Påskdagen", :regions => [:se]},
        {:function => "easter(year)", :function_arguments => [:year], :function_modifier => 1, :name => "Annandag påsk", :regions => [:se]},
        {:function => "easter(year)", :function_arguments => [:year], :function_modifier => 39, :name => "Kristi himmelsfärdsdag", :regions => [:se]},
        {:function => "easter(year)", :function_arguments => [:year], :function_modifier => 49, :name => "Pingstdagen", :regions => [:se]},
        {:function => "se_alla_helgons_dag(year)", :function_arguments => [:year], :name => "Alla helgons dag", :regions => [:se]}],
  1 => [{:mday => 1, :name => "Nyårsdagen", :regions => [:se]},
        {:mday => 6, :name => "Trettondedag jul", :regions => [:se]}],
  5 => [{:mday => 1, :name => "Första maj", :regions => [:se]}],
  6 => [{:mday => 6, :name => "Nationaldagen", :regions => [:se]},
        {:function => "se_midsommardagen(year)", :function_arguments => [:year], :name => "Midsommardagen", :regions => [:se]},
        {:function => "se_midsommardagen(year)", :function_arguments => [:year], :function_modifier => -1, :type => :informal, :name => "Midsommarafton", :regions => [:se]}],
  12 => [{:mday => 24, :type => :informal, :name => "Julafton", :regions => [:se]},
        {:mday => 25, :name => "Juldagen", :regions => [:se]},
        {:mday => 26, :name => "Annandag jul", :regions => [:se]},
        {:mday => 31, :type => :informal, :name => "Nyårsafton", :regions => [:se]}]
  }
end