Sha256: 92a7eb887b235918d727cb1c8b4a8d6f4acaa56acd2a6d689cac34655bd1501e

Contents?: true

Size: 1.32 KB

Versions: 1

Compression:

Stored size: 1.32 KB

Contents

# frozen_string_literal: true

module Bolognese
  module Writers
    module CrossciteWriter
      def crosscite
        hsh = {
          "id" => identifier,
          "doi" => doi,
          "url" => url,
          "types" => types,
          "creator" => creator,
          "titles" => titles,
          "publisher" => publisher,
          "periodical" => periodical,
          "subjects" => subjects,
          "contributor" => contributor,
          "dates" => dates,
          "publication_year" => publication_year,
          "language" => language,
          "alternate_identifiers" => alternate_identifiers,
          "sizes" => sizes,
          "formats" => formats,
          "version" => version,
          "rights_list" => rights_list,
          "descriptions" => descriptions,
          "volume" => volume,
          "issue" => issue,
          "first_page" => first_page,
          "last_page" => last_page,
          "geo_locations" => geo_locations,
          "funding_references" => funding_references,
          "related_identifiers" => related_identifiers,
          "schema_version" => schema_version,
          "provider_id" => provider_id,
          "client_id" => client_id,
          "provider" => service_provider,
          "state" => state
        }.compact
        JSON.pretty_generate hsh.presence
      end
    end
  end
end

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
bolognese-1.0.7 lib/bolognese/writers/crosscite_writer.rb