Class: Dataverse::Base

Inherits:
Object
  • Object
show all
Extended by:
Forwardable
Defined in:
lib/dataverse/base.rb

Direct Known Subclasses

Dataset, Dataverse

Instance Attribute Summary collapse

Instance Method Summary collapse

Instance Attribute Details

#api_dataObject (readonly)

Returns the value of attribute api_data.



13
14
15
# File 'lib/dataverse/base.rb', line 13

def api_data
  @api_data
end

Instance Method Details

#==(other) ⇒ Object



34
35
36
# File 'lib/dataverse/base.rb', line 34

def ==(other)
  self.api_data == other.api_data
end

#eql?(other) ⇒ Boolean

Returns:

  • (Boolean)


38
39
40
# File 'lib/dataverse/base.rb', line 38

def eql?(other)
  self == other
end

#hashObject



42
43
44
# File 'lib/dataverse/base.rb', line 42

def hash
  api_data.hash
end

#refreshObject



17
18
19
# File 'lib/dataverse/base.rb', line 17

def refresh
  init(get_data)
end