Class: Yt::Collections::Base
- Inherits:
-
Object
- Object
- Yt::Collections::Base
- Includes:
- Actions::DeleteAll, Actions::Insert, Actions::List
- Defined in:
- lib/yt/collections/base.rb
Direct Known Subclasses
Annotations, Authentications, Channels, ContentDetails, DeviceFlows, Ids, PlaylistItems, Playlists, Ratings, Reports, Snippets, StatisticsSets, Statuses, Subscriptions, UserInfos, Videos
Class Method Summary collapse
Instance Method Summary collapse
-
#initialize(options = {}) ⇒ Base
constructor
A new instance of Base.
- #where(conditions = {}) ⇒ Object
Methods included from Actions::List
Constructor Details
#initialize(options = {}) ⇒ Base
Returns a new instance of Base.
13 14 15 16 |
# File 'lib/yt/collections/base.rb', line 13 def initialize( = {}) @parent = [:parent] @auth = [:auth] end |
Class Method Details
.of(parent) ⇒ Object
18 19 20 |
# File 'lib/yt/collections/base.rb', line 18 def self.of(parent) new parent: parent, auth: parent.auth end |
Instance Method Details
#where(conditions = {}) ⇒ Object
22 23 24 25 26 |
# File 'lib/yt/collections/base.rb', line 22 def where(conditions = {}) @items = [] @extra_params = conditions self end |