Class: PuppetLanguageServer::Sidecar::Protocol::Fact

Inherits:
BasePuppetObject show all
Defined in:
lib/puppet-languageserver/sidecar_protocol.rb

Instance Attribute Summary collapse

Attributes inherited from BasePuppetObject

#calling_source, #char, #key, #length, #line, #source

Instance Method Summary collapse

Methods inherited from BaseClass

#==, #eql?, #from_json!, #hash, #to_json

Methods included from Base

#from_json!, #to_json

Instance Attribute Details

#valueObject

Returns the value of attribute value.



509
510
511
# File 'lib/puppet-languageserver/sidecar_protocol.rb', line 509

def value
  @value
end

Instance Method Details

#from_h!(value) ⇒ Object



517
518
519
520
521
522
# File 'lib/puppet-languageserver/sidecar_protocol.rb', line 517

def from_h!(value)
  super

  self.value = value['value']
  self
end

#to_hObject



511
512
513
514
515
# File 'lib/puppet-languageserver/sidecar_protocol.rb', line 511

def to_h
  super.to_h.merge(
    'value' => value
  )
end