Class: Org::Familysearch::Ws::Familytree::V2::Schema::ValueSelection

Inherits:
Object
  • Object
show all
Defined in:
lib/ruby-fs-stack/enunciate/familytree.rb

Overview

Selected Information (Selectable Summary).

Instance Attribute Summary collapse

Class Method Summary collapse

Instance Method Summary collapse

Instance Attribute Details

#contributorObject

The contributor of the selection.



4575
4576
4577
# File 'lib/ruby-fs-stack/enunciate/familytree.rb', line 4575

def contributor
  @contributor
end

#dateObject

The date of the selection.



4573
4574
4575
# File 'lib/ruby-fs-stack/enunciate/familytree.rb', line 4573

def date
  @date
end

Class Method Details

.from_json(o) ⇒ Object

constructs a ValueSelection from a (parsed) JSON hash



4597
4598
4599
4600
4601
4602
4603
4604
4605
# File 'lib/ruby-fs-stack/enunciate/familytree.rb', line 4597

def self.from_json(o)
  if o.nil?
    return nil
  else
    inst = new
    inst.init_jaxb_json_hash o
    return inst
  end
end

Instance Method Details

#init_jaxb_json_hash(_o) ⇒ Object

initializes this ValueSelection with a json hash



4591
4592
4593
4594
# File 'lib/ruby-fs-stack/enunciate/familytree.rb', line 4591

def init_jaxb_json_hash(_o)
  @date = Time.from_json(_o['date']) unless _o['date'].nil?
  @contributor = Org::Familysearch::Ws::Familytree::V2::Schema::EntityReference.from_json(_o['contributor']) unless _o['contributor'].nil?
end

#to_jaxb_json_hashObject

the json hash for this ValueSelection



4578
4579
4580
4581
4582
4583
# File 'lib/ruby-fs-stack/enunciate/familytree.rb', line 4578

def to_jaxb_json_hash
  _h = {}
  _h['date'] = date.to_jaxb_json_hash unless date.nil?
  _h['contributor'] = contributor.to_jaxb_json_hash unless contributor.nil?
  return _h
end

#to_jsonObject

the json (string form) for this ValueSelection



4586
4587
4588
# File 'lib/ruby-fs-stack/enunciate/familytree.rb', line 4586

def to_json
  to_jaxb_json_hash.to_json
end