class ONIX::Collection

Public Instance Methods

collection_title_element() click to toggle source

@return [TitleElement]

# File lib/onix/collection.rb, line 36
def collection_title_element
  distinctive_title = @title_details.distinctive_title.first
  #select { |td| td.type.human=~/DistinctiveTitle/}.first
  if distinctive_title
    distinctive_title.title_elements.collection_level.first
    #select { |te| te.level.human=~/CollectionLevel/ or te.level.human=~/Subcollection/ }.first
  end
end
subtitle() click to toggle source

collection subtitle string @return [String]

# File lib/onix/collection.rb, line 29
def subtitle
  if collection_title_element
    collection_title_element.subtitle
  end
end
title() click to toggle source

collection title string @return [String]

# File lib/onix/collection.rb, line 21
def title
  if collection_title_element
    collection_title_element.title
  end
end