Class: AssetLink
- Inherits:
-
ApplicationRecord
- Object
- ActiveRecord::Base
- ApplicationRecord
- AssetLink
- Includes:
- Api::AssetLinkIO::Extensions, Uuid::Uuidable
- Defined in:
- app/models/asset_link.rb
Overview
AssetLink is powered by acts-as-dag Briefly, acts-as-dag attempts to implement a directed-acyclic-graph in a relational database. In order to optimize for retrieval it inserts an AssetLink record for EACH ancestor-descendant link. As a result, it is possible to retrieve ALL ancestors for a given plate in a single query. On the flip side, this makes insert operations more expensive as the graph grows.
As a result, try and avoid adding wells in to asset links, and link between Labware only.
The children,parents,ancestors,descendants methods are all Rails associations, and so can have further scopes applied to them
Defined Under Namespace
Modules: Associations Classes: Job
Instance Method Summary collapse
Methods included from Uuid::Uuidable
included, #unsaved_uuid!, #uuid
Methods included from Api::AssetLinkIO::Extensions
Methods inherited from ApplicationRecord
convert_labware_to_receptacle_for, find_by_id_or_name, find_by_id_or_name!
Methods included from Squishify
Methods included from Warren::BroadcastMessages
#broadcast, included, #queue_associated_for_broadcast, #queue_for_broadcast, #warren
Instance Method Details
#destroy! ⇒ Object
33 34 |
# File 'app/models/asset_link.rb', line 33 def destroy! end |