Class: OpenBEL::Routes::Evidence

Inherits:
Base
  • Object
show all
Includes:
Evidence::FacetFilter, Helpers, OpenBEL::Resource::Evidence
Defined in:
app/openbel/api/routes/evidence.rb

Constant Summary

Constants included from Helpers

Helpers::DEFAULT_CONTENT_TYPE, Helpers::DEFAULT_CONTENT_TYPE_ID

Constants included from Evidence::FacetFilter

Evidence::FacetFilter::EMPTY, Evidence::FacetFilter::EVIDENCE_PARTS

Constants inherited from Base

Base::DEFAULT_CONTENT_TYPE, Base::DEFAULT_CONTENT_TYPE_ID, Base::RESOURCE_SERIALIZERS, Base::SCHEMA_BASE_URL, Base::SPOKEN_CONTENT_TYPES

Constants included from Schemas

Schemas::COMPILED_SCHEMAS, Schemas::SCHEMA_DIR, Schemas::SUFFIX

Constants included from OpenBEL::Resource::Namespaces

OpenBEL::Resource::Namespaces::VOCABULARY_RDF

Constants included from OpenBEL::Resource::Annotations

OpenBEL::Resource::Annotations::VOCABULARY_RDF

Instance Method Summary collapse

Methods included from Helpers

#incomplete_filters, #invalid_fts_filters, #parse_filters, #render_evidence_collection, #validate_filters!, #wants_default?

Methods included from Evidence::FacetFilter

#make_filter, #map_citation_facets, #map_evidence_facets, #map_experiment_context_facets, #map_metadata_facets

Methods included from Schemas

#validate

Constructor Details

#initialize(app) ⇒ Evidence

Returns a new instance of Evidence.



18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
# File 'app/openbel/api/routes/evidence.rb', line 18

def initialize(app)
  super

  mongo = OpenBEL::Settings[:evidence_store][:mongo]
  @api  = OpenBEL::Evidence::Evidence.new(mongo)

  # RdfRepository using Jena
  @rr = BEL::RdfRepository.plugins[:jena].create_repository(
    :tdb_directory => OpenBEL::Settings[:resource_rdf][:jena][:tdb_directory]
  )

  # Annotations using RdfRepository
  annotations = BEL::Resource::Annotations.new(@rr)

  @annotation_transform = AnnotationTransform.new(annotations)
  @annotation_grouping_transform = AnnotationGroupingTransform.new
end