Class: V1::Pacbio::RequestResource
- Inherits:
-
JSONAPI::Resource
- Object
- JSONAPI::Resource
- V1::Pacbio::RequestResource
- Includes:
- Shared::SourceIdentifierFilterable
- Defined in:
- app/resources/v1/pacbio/request_resource.rb
Overview
Provides a JSON:API representation of Pacbio::Request.
For more information about JSON:API see the JSON:API Specifications or look at the JSONAPI::Resources package for the service implementation of the JSON:API standard. This resource represents a Pacbio Request and can return all requests, a single request or multiple requests along with their relationships.
Filters:
-
sample_name
-
source_identifier
-
species
Primary relationships:
-
well WellResource
-
plate PlateResource
-
tube TubeResource
Relationship trees:
-
well.plate
-
plate.wells
-
tube.requests
Direct Known Subclasses
Instance Attribute Summary collapse
-
#barcode ⇒ String
readonly
The barcode of the sample.
-
#cost_code ⇒ String
The cost code.
-
#created_at ⇒ String
readonly
The creation time of the request.
-
#estimate_of_gb_required ⇒ Float
The estimated gigabytes required.
-
#external_study_id ⇒ String
The external study ID.
-
#library_type ⇒ String
The type of the library.
-
#number_of_smrt_cells ⇒ Integer
The number of SMRT cells.
-
#sample_name ⇒ String
readonly
The name of the sample.
-
#sample_retention_instrction ⇒ String
readonly
The retention instruction of the request.
-
#sample_species ⇒ String
readonly
The species of the sample.
-
#source_identifier ⇒ String
readonly
The source identifier of the request.
Class Method Summary collapse
Instance Method Summary collapse
Instance Attribute Details
#barcode ⇒ String (readonly)
Returns the barcode of the sample.
73 74 75 |
# File 'app/resources/v1/pacbio/request_resource.rb', line 73 attributes :sample_name, :barcode, :sample_species, :created_at, :source_identifier, :sample_retention_instruction, readonly: true |
#cost_code ⇒ String
Returns the cost code.
59 |
# File 'app/resources/v1/pacbio/request_resource.rb', line 59 attributes(*::Pacbio.request_attributes) |
#created_at ⇒ String (readonly)
Returns the creation time of the request.
73 74 75 |
# File 'app/resources/v1/pacbio/request_resource.rb', line 73 attributes :sample_name, :barcode, :sample_species, :created_at, :source_identifier, :sample_retention_instruction, readonly: true |
#estimate_of_gb_required ⇒ Float
Returns the estimated gigabytes required.
59 |
# File 'app/resources/v1/pacbio/request_resource.rb', line 59 attributes(*::Pacbio.request_attributes) |
#external_study_id ⇒ String
Returns the external study ID.
59 |
# File 'app/resources/v1/pacbio/request_resource.rb', line 59 attributes(*::Pacbio.request_attributes) |
#library_type ⇒ String
Returns the type of the library.
59 |
# File 'app/resources/v1/pacbio/request_resource.rb', line 59 attributes(*::Pacbio.request_attributes) |
#number_of_smrt_cells ⇒ Integer
Returns the number of SMRT cells.
59 |
# File 'app/resources/v1/pacbio/request_resource.rb', line 59 attributes(*::Pacbio.request_attributes) |
#sample_name ⇒ String (readonly)
Returns the name of the sample.
73 74 75 |
# File 'app/resources/v1/pacbio/request_resource.rb', line 73 attributes :sample_name, :barcode, :sample_species, :created_at, :source_identifier, :sample_retention_instruction, readonly: true |
#sample_retention_instrction ⇒ String (readonly)
Returns the retention instruction of the request.
73 74 75 |
# File 'app/resources/v1/pacbio/request_resource.rb', line 73 attributes :sample_name, :barcode, :sample_species, :created_at, :source_identifier, :sample_retention_instruction, readonly: true |
#sample_species ⇒ String (readonly)
Returns the species of the sample.
73 74 75 |
# File 'app/resources/v1/pacbio/request_resource.rb', line 73 attributes :sample_name, :barcode, :sample_species, :created_at, :source_identifier, :sample_retention_instruction, readonly: true |
#source_identifier ⇒ String (readonly)
Returns the source identifier of the request.
73 74 75 |
# File 'app/resources/v1/pacbio/request_resource.rb', line 73 attributes :sample_name, :barcode, :sample_species, :created_at, :source_identifier, :sample_retention_instruction, readonly: true |
Class Method Details
.default_sort ⇒ Object
102 103 104 |
# File 'app/resources/v1/pacbio/request_resource.rb', line 102 def self.default_sort [{ field: 'created_at', direction: :desc }] end |
.records_for_populate(*_args) ⇒ Object
118 119 120 |
# File 'app/resources/v1/pacbio/request_resource.rb', line 118 def self.records_for_populate(*_args) super.preload(:sample, :tube, well: :plate) end |