Class: CabezaDeTermo::JsonSpec::JsonValidatorError

Inherits:
Object
  • Object
show all
Defined in:
lib/cabeza-de-termo/json-spec/walkers/validator/json-validator-error.rb

Instance Method Summary collapse

Constructor Details

#initialize(accessors_chain, message) ⇒ JsonValidatorError

Returns a new instance of JsonValidatorError.



4
5
6
7
# File 'lib/cabeza-de-termo/json-spec/walkers/validator/json-validator-error.rb', line 4

def initialize(accessors_chain, message)
	@accessors_chain = accessors_chain
	@message = message
end

Instance Method Details

#accessors_chainObject



15
16
17
# File 'lib/cabeza-de-termo/json-spec/walkers/validator/json-validator-error.rb', line 15

def accessors_chain()
	@accessors_chain
end

#messageObject

Accessing



11
12
13
# File 'lib/cabeza-de-termo/json-spec/walkers/validator/json-validator-error.rb', line 11

def message()
	@message
end

#to_hashObject

Converting



21
22
23
24
25
26
# File 'lib/cabeza-de-termo/json-spec/walkers/validator/json-validator-error.rb', line 21

def to_hash()
	{
		access_chain: accessors_chain().to_s,
		message: message
	}
end