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

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

Overview

A Family Tree person reference.

Direct Known Subclasses

ParentReference

Instance Attribute Summary collapse

Attributes inherited from EntityReference

#current, #id, #tempId, #version

Class Method Summary collapse

Instance Method Summary collapse

Methods inherited from EntityReference

#to_json

Instance Attribute Details

#genderObject

The gender of the person.



5382
5383
5384
# File 'lib/ruby-fs-stack/enunciate/familytree.rb', line 5382

def gender
  @gender
end

Class Method Details

.from_json(o) ⇒ Object

constructs a PersonReference from a (parsed) JSON hash



5398
5399
5400
5401
5402
5403
5404
5405
5406
# File 'lib/ruby-fs-stack/enunciate/familytree.rb', line 5398

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 PersonReference with a json hash



5392
5393
5394
5395
# File 'lib/ruby-fs-stack/enunciate/familytree.rb', line 5392

def init_jaxb_json_hash(_o)
  super _o
  @gender = String.from_json(_o['gender']) unless _o['gender'].nil?
end

#to_jaxb_json_hashObject

the json hash for this PersonReference



5385
5386
5387
5388
5389
# File 'lib/ruby-fs-stack/enunciate/familytree.rb', line 5385

def to_jaxb_json_hash
  _h = super
  _h['gender'] = gender.to_jaxb_json_hash unless gender.nil?
  return _h
end