Sha256: ee88ce892c24cf3cda4c7656cd07d890258f1648ef67d29e9a6a115ceeff8cb1

Contents?: true

Size: 1.21 KB

Versions: 2

Compression:

Stored size: 1.21 KB

Contents

module Patentscope

  require 'patentscope/version'
  require 'patentscope/client'
  require 'patentscope/configuration'
  require 'patentscope/webservice'
  require 'patentscope/webservice_soap_builder'
  require 'patentscope/pct_doc_number'

  class NoCredentialsError < StandardError; end
  class WrongCredentialsError < StandardError; end
  class BusinessError < StandardError; end
  class WrongNumberFormatError < StandardError; end

  class << self

    def wsdl
      webservice.wsdl
    end

    def get_available_documents(ia_number)
      webservice.get_available_documents(ia_number: ia_number)
    end

    def get_document_content(doc_id)
      webservice.get_document_content(doc_id: doc_id)
    end

    def get_document_ocr_content(doc_id)
      webservice.get_document_ocr_content(doc_id: doc_id)
    end

    def get_iasr(ia_number)
      webservice.get_iasr(ia_number: ia_number)
    end

    def get_document_table_of_contents(doc_id)
      webservice.get_document_table_of_contents(doc_id: doc_id)
    end

    def get_document_content_page(doc_id, page_id)
      webservice.get_document_content_page(doc_id: doc_id, page_id: page_id)
    end

    private

    def webservice
      Webservice.new
    end
  end
end

Version data entries

2 entries across 2 versions & 1 rubygems

Version Path
patentscope-0.0.2 lib/patentscope.rb
patentscope-0.0.1 lib/patentscope.rb