Class: Exlibris::Primo::Link

Inherits:
Object
  • Object
show all
Includes:
Abstract, Config::Attributes, WriteAttributes
Defined in:
lib/exlibris/primo/link.rb

Overview

Abstract class representing a link in Primo.

Direct Known Subclasses

Fulltext, RelatedLink, TableOfContents

Instance Attribute Summary collapse

Instance Method Summary collapse

Methods included from WriteAttributes

#write_attributes

Methods included from Config::Attributes

#availability_statuses, #base_url, #config, #facet_collections, #facet_labels, #facet_resource_types, #facet_top_level, #institutions, #libraries, #proxy_url, #sources

Methods included from Abstract

included

Constructor Details

#initialize(*args) ⇒ Link

Returns a new instance of Link.



16
17
18
19
20
21
# File 'lib/exlibris/primo/link.rb', line 16

def initialize *args
  # URLs may have XML escaped ampersands
  # so we need to account for that.
  args.last[:url].gsub!("&", "&") unless args.last.nil?
  super(*args)
end

Instance Attribute Details

#displayObject

Returns the value of attribute display.



13
14
15
# File 'lib/exlibris/primo/link.rb', line 13

def display
  @display
end

#display_codeObject

Returns the value of attribute display_code.



13
14
15
# File 'lib/exlibris/primo/link.rb', line 13

def display_code
  @display_code
end

#institutionObject

Returns the value of attribute institution.



13
14
15
# File 'lib/exlibris/primo/link.rb', line 13

def institution
  @institution
end

#notesObject

Returns the value of attribute notes.



13
14
15
# File 'lib/exlibris/primo/link.rb', line 13

def notes
  @notes
end

#original_idObject

Returns the value of attribute original_id.



13
14
15
# File 'lib/exlibris/primo/link.rb', line 13

def original_id
  @original_id
end

#record_idObject

Returns the value of attribute record_id.



13
14
15
# File 'lib/exlibris/primo/link.rb', line 13

def record_id
  @record_id
end

#subfieldsObject

Returns the value of attribute subfields.



13
14
15
# File 'lib/exlibris/primo/link.rb', line 13

def subfields
  @subfields
end

#urlObject

Returns the value of attribute url.



13
14
15
# File 'lib/exlibris/primo/link.rb', line 13

def url
  @url
end