class IsoBibItem::ContributionInfo

Contribution info.

Attributes

entity[R]

@return

[IsoBibItem::Person, IsoBibItem::Organization,
 IsoBibItem::IsoProjectGroup]
role[R]

@return [Array<IsoBibItem::ContributorRole>]

Public Class Methods

new(entity:, role: ['publisher']) click to toggle source

@param entity [IsoBibItem::Person, IsoBibItem::Organization,

IsoBibItem::IsoProjectGroup]

@param role [Array<String>]

# File lib/iso_bib_item/contribution_info.rb, line 45
def initialize(entity:, role: ['publisher'])
  @entity = entity
  @role   = role.map { |r| ContributorRole.new(*r) }
end

Public Instance Methods

to_xml(builder) click to toggle source
# File lib/iso_bib_item/contribution_info.rb, line 50
def to_xml(builder)
  entity.to_xml builder
end