Class: Warb::Components::Org

Inherits:
Object
  • Object
show all
Defined in:
lib/warb/components/org.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(**params) ⇒ Org

Returns a new instance of Org.



8
9
10
11
12
# File 'lib/warb/components/org.rb', line 8

def initialize(**params)
  @company = params[:company]
  @department = params[:department]
  @title = params[:title]
end

Instance Attribute Details

#companyObject

Returns the value of attribute company.



6
7
8
# File 'lib/warb/components/org.rb', line 6

def company
  @company
end

#departmentObject

Returns the value of attribute department.



6
7
8
# File 'lib/warb/components/org.rb', line 6

def department
  @department
end

#titleObject

Returns the value of attribute title.



6
7
8
# File 'lib/warb/components/org.rb', line 6

def title
  @title
end

Instance Method Details

#to_hObject



14
15
16
17
18
19
20
# File 'lib/warb/components/org.rb', line 14

def to_h
  {
    company: company,
    department: department,
    title: title
  }
end