Class: BucketCake::Base

Inherits:
Object
  • Object
show all
Defined in:
lib/bucket_cake/base.rb

Direct Known Subclasses

Latest, Range

Defined Under Namespace

Classes: Latest, Range

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(cursor) ⇒ Base

Returns a new instance of Base.



30
31
32
33
# File 'lib/bucket_cake/base.rb', line 30

def initialize(cursor)
  raise 'BucketCake: cursor has invalid format!' unless cursor.nil? || cursor =~ CURSOR_REGEXP
  @cursor = cursor
end

Instance Attribute Details

#cursorObject (readonly)

Returns the value of attribute cursor.



28
29
30
# File 'lib/bucket_cake/base.rb', line 28

def cursor
  @cursor
end

Instance Method Details

#itemsObject



35
36
37
# File 'lib/bucket_cake/base.rb', line 35

def items
  get source, self.class::PROTOCLASS
end