Class: Pluct::Schema

Inherits:
Object
  • Object
show all
Includes:
Helpers::Request
Defined in:
lib/pluct/schema.rb

Constant Summary

Constants included from Helpers::Request

Helpers::Request::DEFAULT_HEADERS

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(path) ⇒ Schema

Returns a new instance of Schema.



7
8
9
10
11
# File 'lib/pluct/schema.rb', line 7

def initialize(path)
  @path = path
  @data = get_content
  @links = @data.links
end

Instance Attribute Details

#dataObject (readonly)

Returns the value of attribute data.



5
6
7
# File 'lib/pluct/schema.rb', line 5

def data
  @data
end

Returns the value of attribute links.



5
6
7
# File 'lib/pluct/schema.rb', line 5

def links
  @links
end

#pathObject (readonly)

Returns the value of attribute path.



5
6
7
# File 'lib/pluct/schema.rb', line 5

def path
  @path
end

Instance Method Details

#to_sObject



13
14
15
# File 'lib/pluct/schema.rb', line 13

def to_s
  @path  
end