Class: GraphQL::Dataloader::NullDataloader
- Inherits:
-
GraphQL::Dataloader
- Object
- GraphQL::Dataloader
- GraphQL::Dataloader::NullDataloader
- Defined in:
- lib/graphql/dataloader/null_dataloader.rb
Overview
The default implementation of dataloading -- all no-ops.
The Dataloader interface isn't public, but it enables simple internal code while adding the option to add Dataloader.
Instance Attribute Summary
Attributes inherited from GraphQL::Dataloader
Instance Method Summary collapse
- #append_job ⇒ Object
-
#run ⇒ Object
These are all no-ops because code was executed synchronously.
- #run_isolated ⇒ Object
- #yield ⇒ Object
Methods inherited from GraphQL::Dataloader
#cleanup_fiber, #clear_cache, #get_fiber_variables, #initialize, #nonblocking?, #run_fiber, #set_fiber_variables, #spawn_fiber, use, #with, with_dataloading
Constructor Details
This class inherits a constructor from GraphQL::Dataloader
Instance Method Details
#append_job ⇒ Object
18 19 20 21 |
# File 'lib/graphql/dataloader/null_dataloader.rb', line 18 def append_job yield nil end |
#run ⇒ Object
These are all no-ops because code was executed synchronously.
12 |
# File 'lib/graphql/dataloader/null_dataloader.rb', line 12 def run; end |
#run_isolated ⇒ Object
13 |
# File 'lib/graphql/dataloader/null_dataloader.rb', line 13 def run_isolated; yield; end |