Class: ScopusRemote
- Inherits:
 - 
      Object
      
        
- Object
 - ScopusRemote
 
 
- Defined in:
 - lib/scopus_remote.rb
 
Instance Attribute Summary collapse
- 
  
    
      #error  ⇒ Object 
    
    
  
  
  
  
    
      readonly
    
    
  
  
  
  
  
  
    
Returns the value of attribute error.
 - 
  
    
      #scopus  ⇒ Object 
    
    
  
  
  
  
    
      readonly
    
    
  
  
  
  
  
  
    
Returns the value of attribute scopus.
 
Instance Method Summary collapse
- 
  
    
      #initialize  ⇒ ScopusRemote 
    
    
  
  
  
    constructor
  
  
  
  
  
  
  
    
A new instance of ScopusRemote.
 - #xml_abstract_by_id(id, type = "doi") ⇒ Object
 
Constructor Details
#initialize ⇒ ScopusRemote
Returns a new instance of ScopusRemote.
      35 36 37 38  | 
    
      # File 'lib/scopus_remote.rb', line 35 def initialize @scopus=ElsevierApi::Connection.new(ENV["SCOPUS_KEY"], :proxy_host => ENV["PROXY_HOST"], :proxy_port => ENV["PROXY_PORT"], :proxy_user => ENV["PROXY_USER"], :proxy_pass => ENV["PROXY_PASS"]) @error=nil end  | 
  
Instance Attribute Details
#error ⇒ Object (readonly)
Returns the value of attribute error.
      33 34 35  | 
    
      # File 'lib/scopus_remote.rb', line 33 def error @error end  | 
  
#scopus ⇒ Object (readonly)
Returns the value of attribute scopus.
      32 33 34  | 
    
      # File 'lib/scopus_remote.rb', line 32 def scopus @scopus end  | 
  
Instance Method Details
#xml_abstract_by_id(id, type = "doi") ⇒ Object
      42 43 44 45 46 47 48 49 50 51 52 53  | 
    
      # File 'lib/scopus_remote.rb', line 42 def xml_abstract_by_id(id, type="doi") uri_abstract=@scopus.get_uri_abstract(CGI.escapeElement(id), type=type, {}) xml=@scopus.retrieve_response(uri_abstract) if @scopus.error #$log.info(@scopus.error_msg) @error=@scopus.error_msg false else xml end end  |