Class: Userlist::Push::Relation

Inherits:
Object
  • Object
show all
Defined in:
lib/userlist/push/relation.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(scope, type, operations = []) ⇒ Relation



4
5
6
7
8
9
# File 'lib/userlist/push/relation.rb', line 4

def initialize(scope, type, operations = [])
  @scope = scope
  @type = type

  operations.each { |operation| singleton_class.send(:include, operation::ClassMethods) }
end

Instance Attribute Details

#scopeObject (readonly)

Returns the value of attribute scope.



11
12
13
# File 'lib/userlist/push/relation.rb', line 11

def scope
  @scope
end

#typeObject (readonly)

Returns the value of attribute type.



11
12
13
# File 'lib/userlist/push/relation.rb', line 11

def type
  @type
end