Class: CanTango::PermitEngine::Finder

Inherits:
Object
  • Object
show all
Defined in:
lib/cantango/permit_engine/finder.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(user_account, name) ⇒ Finder

Returns a new instance of Finder.



7
8
9
10
# File 'lib/cantango/permit_engine/finder.rb', line 7

def initialize , name
  @user_account = 
  @name = name
end

Instance Attribute Details

#nameObject (readonly)

This class is used to find the right permit, possible scoped for a specific user account



5
6
7
# File 'lib/cantango/permit_engine/finder.rb', line 5

def name
  @name
end

#user_accountObject (readonly)

This class is used to find the right permit, possible scoped for a specific user account



5
6
7
# File 'lib/cantango/permit_engine/finder.rb', line 5

def 
  @user_account
end

Instance Method Details

#get_permitObject



12
13
14
15
# File 'lib/cantango/permit_engine/finder.rb', line 12

def get_permit
  raise find_error if !retrieve_permit
  retrieve_permit
end