Class: Cucumber::Core::Gherkin::Document

Inherits:
Object
  • Object
show all
Defined in:
lib/cucumber/core/gherkin/document.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(uri, body) ⇒ Document

Returns a new instance of Document.



8
9
10
11
# File 'lib/cucumber/core/gherkin/document.rb', line 8

def initialize(uri, body)
  @uri = uri
  @body = body
end

Instance Attribute Details

#bodyObject (readonly)

Returns the value of attribute body.



6
7
8
# File 'lib/cucumber/core/gherkin/document.rb', line 6

def body
  @body
end

#uriObject (readonly)

Returns the value of attribute uri.



6
7
8
# File 'lib/cucumber/core/gherkin/document.rb', line 6

def uri
  @uri
end

Instance Method Details

#==(other) ⇒ Object



17
18
19
# File 'lib/cucumber/core/gherkin/document.rb', line 17

def ==(other)
  to_s == other.to_s
end

#to_sObject



13
14
15
# File 'lib/cucumber/core/gherkin/document.rb', line 13

def to_s
  body
end