Class: ListingIssues::BaseAdapter
- Inherits:
-
Object
- Object
- ListingIssues::BaseAdapter
- Defined in:
- app/services/listing_issues/base_adapter.rb
Overview
Interface every provider adapter implements. An adapter knows (a) which
catalog items to reconcile this run and (b) the current set of listing
issues for a given item — both derived from that provider's own data, with
no external API calls (the marketplace pulls already persist the signals).
Direct Known Subclasses
Instance Method Summary collapse
-
#candidate_item_ids ⇒ Array<Integer>
catalog_item ids to reconcile: every item that currently shows a signal, plus every item with an open issue already recorded for this provider (so cleared issues get auto-resolved on the next run).
-
#issues_for(_catalog_item) ⇒ Array<ListingIssues::Issue>
Current issues for the item.
-
#provider ⇒ String
Provider key stored on ListingIssue#provider.
Instance Method Details
#candidate_item_ids ⇒ Array<Integer>
catalog_item ids to reconcile: every item that currently shows a signal,
plus every item with an open issue already recorded for this provider (so
cleared issues get auto-resolved on the next run).
18 19 20 |
# File 'app/services/listing_issues/base_adapter.rb', line 18 def candidate_item_ids raise NotImplementedError end |
#issues_for(_catalog_item) ⇒ Array<ListingIssues::Issue>
Returns current issues for the item.
24 25 26 |
# File 'app/services/listing_issues/base_adapter.rb', line 24 def issues_for(_catalog_item) raise NotImplementedError end |
#provider ⇒ String
Returns provider key stored on ListingIssue#provider.
10 11 12 |
# File 'app/services/listing_issues/base_adapter.rb', line 10 def provider raise NotImplementedError end |