Class: TudlaContracts::Integrations::HostInterface

Inherits:
Object
  • Object
show all
Defined in:
lib/tudla_contracts/integrations/host_interface.rb

Overview

Host application interface for TudlaContracts

Instance Method Summary collapse

Instance Method Details

#available_projects_for_user(user) ⇒ Array<Project>

Returns an array of projects available to the user

Parameters:

  • user (User) —

    The host application User object

Returns:

Raises:

  • (NotImplementedError)


27
28
29
# File 'lib/tudla_contracts/integrations/host_interface.rb', line 27

def available_projects_for_user(user)
  raise NotImplementedError, "#{self.class.name} must implement #avaliable_projects_for_user"
end

#available_tasks_for_user(user) ⇒ Array<Task>

Returns an array of tasks available to the user

Parameters:

  • user (User) —

    The host application User object

Returns:

Raises:

  • (NotImplementedError)


20
21
22
# File 'lib/tudla_contracts/integrations/host_interface.rb', line 20

def available_tasks_for_user(user)
  raise NotImplementedError, "#{self.class.name} must implement #avaliable_tasks_for_user"
end

#available_users_for_user(user) ⇒ Array<User>

Returns an array of users available to the user

Parameters:

  • user (User) —

    The host application User object

Returns:

Raises:

  • (NotImplementedError)


13
14
15
# File 'lib/tudla_contracts/integrations/host_interface.rb', line 13

def available_users_for_user(user)
  raise NotImplementedError, "#{self.class.name} must implement #avaliable_users_for_user"
end

#find_task(task_id) ⇒ Task

Returns a Tudla task by id

Parameters:

  • task_id (Integer) —

    The Tudla task id

Returns:

Raises:

  • (NotImplementedError)


34
35
36
# File 'lib/tudla_contracts/integrations/host_interface.rb', line 34

def find_task(task_id)
  raise NotImplementedError, "#{self.class.name} must implement #find_task"
end