Class: Cadenya::Types::Page

Inherits:
Object
  • Object
show all
Defined in:
lib/cadenya/types.rb

Instance Attribute Summary collapse

Class Method Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(next_cursor: nil) ⇒ Page

Returns a new instance of Page.



4494
4495
4496
# File 'lib/cadenya/types.rb', line 4494

def initialize(next_cursor: nil)
  @next_cursor = next_cursor
end

Instance Attribute Details

#next_cursorObject (readonly)

Returns the value of attribute next_cursor.



4492
4493
4494
# File 'lib/cadenya/types.rb', line 4492

def next_cursor
  @next_cursor
end

Class Method Details

.from_json(data) ⇒ Object



4498
4499
4500
4501
4502
# File 'lib/cadenya/types.rb', line 4498

def self.from_json(data)
  new(
    next_cursor: data["nextCursor"],
  )
end

Instance Method Details

#to_hObject



4504
4505
4506
4507
4508
# File 'lib/cadenya/types.rb', line 4504

def to_h
  {
    next_cursor: Util.plain(@next_cursor),
  }.reject { |_k, v| v.nil? }
end