class OldPlaid::Category

Attributes

hierarchy[RW]
id[RW]
type[RW]

Public Class Methods

all(res) click to toggle source

API: semi-private This method takes an array returned from the API and instantiates all of the categories

# File lib/old_plaid/models/category.rb, line 13
def self.all(res)
  res.map { |cat| new(cat) }
end
new(fields = {}) click to toggle source
# File lib/old_plaid/models/category.rb, line 5
def initialize(fields = {})
  @type = fields['type']
  @hierarchy = fields['hierarchy']
  @id = fields['id']
end