Class: DiscoveryIndexer::InputXml::PurlxmlModel

Inherits:
Object
  • Object
show all
Defined in:
lib/discovery-indexer/reader/purlxml_model.rb

Instance Attribute Summary collapse

Instance Attribute Details

#barcodeString

Returns the barcode attribute in identity_metadata.

Returns:

  • (String)

    the barcode attribute in identity_metadata



102
103
104
# File 'lib/discovery-indexer/reader/purlxml_model.rb', line 102

def barcode
  @barcode
end

#catkeyString

Returns the catkey attribute in identity_metadata.

Returns:

  • (String)

    the catkey attribute in identity_metadata



94
95
96
# File 'lib/discovery-indexer/reader/purlxml_model.rb', line 94

def catkey
  @catkey
end

#collection_druidsArray<String>

Returns bare druids of the collections that this druid is a member of.

Examples:

["aa11aaa1111","bb111bb1111"]

Returns:

  • (Array<String>)

    bare druids of the collections that this druid is a member of



52
53
54
# File 'lib/discovery-indexer/reader/purlxml_model.rb', line 52

def collection_druids
  @collection_druids
end

#constituent_druidsArray<String>

Returns bare druids of the objects that this druid is a constituent of.

Examples:

["aa11aaa1111","bb111bb1111"]

Returns:

  • (Array<String>)

    bare druids of the objects that this druid is a constituent of



58
59
60
# File 'lib/discovery-indexer/reader/purlxml_model.rb', line 58

def constituent_druids
  @constituent_druids
end

#content_metadataNokogiri::XML

Returns The content_metadata as extracted from public xml.

Returns:

  • (Nokogiri::XML)

    The content_metadata as extracted from public xml



14
15
16
# File 'lib/discovery-indexer/reader/purlxml_model.rb', line 14

def 
  @content_metadata
end

Returns the copyright statement from rights metadata.

Returns:

  • (String)

    the copyright statement from rights metadata



110
111
112
# File 'lib/discovery-indexer/reader/purlxml_model.rb', line 110

def copyright
  @copyright
end

#dcNokogiri::XML

Returns The dc element as extracted from public xml.

Returns:

  • (Nokogiri::XML)

    The dc element as extracted from public xml



26
27
28
# File 'lib/discovery-indexer/reader/purlxml_model.rb', line 26

def dc
  @dc
end

#dor_content_typeString

Returns The dor_content_type as extracted from public xml content_metadata.

Returns:

  • (String)

    The dor_content_type as extracted from public xml content_metadata.



42
43
44
# File 'lib/discovery-indexer/reader/purlxml_model.rb', line 42

def dor_content_type
  @dor_content_type
end

#druidString

Returns The druid value eg., ab123cd4567.

Returns:

  • (String)

    The druid value eg., ab123cd4567



6
7
8
# File 'lib/discovery-indexer/reader/purlxml_model.rb', line 6

def druid
  @druid
end

#encoded_thumbString

Returns a thumbnail image if it exists in the PURL, encoded as necessary.

Examples:

"oo000oo0001%2Fpc0065_b08_f10_i031.jp2"

Returns:

  • (String)

    a thumbnail image if it exists in the PURL, encoded as necessary



82
83
84
# File 'lib/discovery-indexer/reader/purlxml_model.rb', line 82

def encoded_thumb
  @encoded_thumb
end

#file_idsArray

Returns a list of the file ids in the content_metadata.

Examples:

["pc0065_b08_f10_i031.txt","pc0065_b08_f10_i032.txt"]

Returns:

  • (Array)

    a list of the file ids in the content_metadata



64
65
66
# File 'lib/discovery-indexer/reader/purlxml_model.rb', line 64

def file_ids
  @file_ids
end

#identity_metadataNokogiri::XML

Returns The identity_metadata as extracted from public xml.

Returns:

  • (Nokogiri::XML)

    The identity_metadata as extracted from public xml



18
19
20
# File 'lib/discovery-indexer/reader/purlxml_model.rb', line 18

def 
  @identity_metadata
end

#image_idsArray

Returns a list of the image ids in the content_metadata.

Examples:

["pc0065_b08_f10_i031.jp2","pc0065_b08_f10_i032.jp2"]

Returns:

  • (Array)

    a list of the image ids in the content_metadata



70
71
72
# File 'lib/discovery-indexer/reader/purlxml_model.rb', line 70

def image_ids
  @image_ids
end

#is_collectionBoolean

Returns true if the item type is collection in the identity_metadata.

Returns:

  • (Boolean)

    true if the item type is collection in the identity_metadata



46
47
48
# File 'lib/discovery-indexer/reader/purlxml_model.rb', line 46

def is_collection
  @is_collection
end

#labelString

Returns the objectLabel attribute in identity_metadata.

Returns:

  • (String)

    the objectLabel attribute in identity_metadata



106
107
108
# File 'lib/discovery-indexer/reader/purlxml_model.rb', line 106

def label
  @label
end

#previous_catkeysArray

Returns the previous catkey attribute in identity_metadata.

Returns:

  • (Array)

    the previous catkey attribute in identity_metadata



98
99
100
# File 'lib/discovery-indexer/reader/purlxml_model.rb', line 98

def previous_catkeys
  @previous_catkeys
end

#public_xmlNokogiri::XML

Returns The publix xml as retrieved from purl server.

Returns:

  • (Nokogiri::XML)

    The publix xml as retrieved from purl server



10
11
12
# File 'lib/discovery-indexer/reader/purlxml_model.rb', line 10

def public_xml
  @public_xml
end

#rdfNokogiri::XML

Returns The rdf element as extracted from public xml.

Returns:

  • (Nokogiri::XML)

    The rdf element as extracted from public xml



30
31
32
# File 'lib/discovery-indexer/reader/purlxml_model.rb', line 30

def rdf
  @rdf
end

#release_tags_hashHash

Returns The release_tag in hash format as extracted from public xml ReleaseData element.

Examples:

!{"target1"=>true, "target2"=>false}

Returns:

  • (Hash)

    The release_tag in hash format as extracted from public xml ReleaseData element.



37
38
39
# File 'lib/discovery-indexer/reader/purlxml_model.rb', line 37

def release_tags_hash
  @release_tags_hash
end

#rights_metadataNokogiri::XML

Returns The rights_metadata as extracted from public xml.

Returns:

  • (Nokogiri::XML)

    The rights_metadata as extracted from public xml



22
23
24
# File 'lib/discovery-indexer/reader/purlxml_model.rb', line 22

def 
  @rights_metadata
end

#source_idString

Returns the sourceid from identity metadata.

Returns:

  • (String)

    the sourceid from identity metadata



118
119
120
# File 'lib/discovery-indexer/reader/purlxml_model.rb', line 118

def source_id
  @source_id
end

#sw_image_idsArray

Returns a list of the image ids and corresponding druids separator from the file and externalFile tags in the content_metadata specifically for Searchworks.

Examples:

["xx888yy9999/pc0065_b08_f10_i031.jp2","aa111bb2222/pc0065_b08_f10_i032.jp2"]

Returns:

  • (Array)

    a list of the image ids and corresponding druids separator from the file and externalFile tags in the content_metadata specifically for Searchworks



90
91
92
# File 'lib/discovery-indexer/reader/purlxml_model.rb', line 90

def sw_image_ids
  @sw_image_ids
end

#thumbString

Returns a thumbnail image if it exists in the PURL, encoded as necessary.

Examples:

"oo000oo0001%2Fpc0065_b08_f10_i031.jp2"

Returns:

  • (String)

    a thumbnail image if it exists in the PURL, encoded as necessary



76
77
78
# File 'lib/discovery-indexer/reader/purlxml_model.rb', line 76

def thumb
  @thumb
end

#use_and_reproductionString

Returns the use and reproduction statement from rights metadata.

Returns:

  • (String)

    the use and reproduction statement from rights metadata



114
115
116
# File 'lib/discovery-indexer/reader/purlxml_model.rb', line 114

def use_and_reproduction
  @use_and_reproduction
end