Sha256: bf7500c1f64566a81a38159f333116a68b14bdab57522b2a8cabb4a308cd9656
Contents?: true
Size: 524 Bytes
Versions: 5
Compression:
Stored size: 524 Bytes
Contents
require 'rexml/document' require 'moblues/data_model/relationship' module Moblues module Reader class Relationship def relationship(xml) DataModel::Relationship.new( name: xml.attributes['name'], destination_entity: xml.attributes['destinationEntity'], to_many: opt_bool(xml.attributes['toMany']), ordered: opt_bool(xml.attributes['ordered']) ) end private def opt_bool(str_value) str_value == 'YES' end end end end
Version data entries
5 entries across 5 versions & 1 rubygems