Class: Freckle::Entry

Inherits:
Base
  • Object
show all
Defined in:
lib/freckle.rb

Instance Attribute Summary

Attributes inherited from Base

#attributes

Class Method Summary collapse

Instance Method Summary collapse

Methods inherited from Base

#<=>, first, #id, #initialize, #method_missing

Constructor Details

This class inherits a constructor from Freckle::Base

Dynamic Method Handling

This class handles dynamic methods through the method_missing method in the class Freckle::Base

Class Method Details

.all(options = {}) ⇒ Object



110
111
112
# File 'lib/freckle.rb', line 110

def self.all(options = {})
  super(:entries, options)
end

Instance Method Details

#project(options = {}) ⇒ Object



113
114
115
# File 'lib/freckle.rb', line 113

def project(options = {})
  @connection.projects(options).detect{ |project| project.id == self.project_id }
end

#user(options = {}) ⇒ Object



116
117
118
# File 'lib/freckle.rb', line 116

def user(options = {})
  @connection.users(options).detect{ |user| user.id == self.user_id }
end