Class: LWS::Resource::Collection
- Inherits:
-
Generic::Model
- Object
- Spyke::Base
- Generic::Model
- LWS::Resource::Collection
- Defined in:
- lib/lws/apps/resource.rb
Overview
The collection class
There are two ways to view collections. Either it is viewed as a set of items (see #items), or it is viewed as something that is associated with one or more meta collections that each have specific item objects (see for example #feed, #image, #images, etc.).
Defined Under Namespace
Classes: Config, Feed, Image, Item, Post, Video, Vimeo, WeatherLocation, YouTube
Instance Attribute Summary collapse
-
#account ⇒ LWS::Auth::Account
The account of the user that created the collection.
-
#account_id ⇒ Integer
The ID of the account of the user that created the collection.
-
#company ⇒ LWS::Auth::Company
The company the collection belongs to.
-
#company_id ⇒ Integer
The ID of the company the collection belongs to.
-
#deleted_at ⇒ String?
The timestamp of when the collection was deleted.
-
#description ⇒ String
The description of the collection.
-
#email ⇒ String?
The email address used for email imports.
-
#folder ⇒ Folder
The folder that the collection is filed in.
-
#folder_id ⇒ Integer
The ID of the folder that the collection is filed in.
-
#item_ids ⇒ Array<Integer>
The ID of the items that are part of the collection.
-
#items ⇒ Array<Collection::Item>
The returned cllection item (sub)class that is determined by the kind of this collection.
-
#kind ⇒ "feed", ...
The name of the class/kind of the collection.
-
#name ⇒ String
The name of the collection.
-
#preview_url ⇒ String
The URL of a preview of the collection.
-
#processing ⇒ Boolean
Whether the collection is being processed (i.e. it is not ready for use).
-
#uuid ⇒ String
The UUID used for unique file name generation.
Attributes inherited from Generic::Model
#created_at, #id, #updated_at, #url, #url_html
Method Summary
Methods inherited from Generic::Model
#deep_dup, #dig, #reload, #rollback, #save
Instance Attribute Details
#account ⇒ LWS::Auth::Account
Returns the account of the user that created the collection.
55 |
# File 'lib/lws/apps/resource.rb', line 55 belongs_to :account, class_name: "LWS::Auth::Account" |
#account_id ⇒ Integer
Returns the ID of the account of the user that created the collection.
60 |
# File 'lib/lws/apps/resource.rb', line 60 attribute :account_id |
#company ⇒ LWS::Auth::Company
Returns the company the collection belongs to.
64 |
# File 'lib/lws/apps/resource.rb', line 64 belongs_to :company, class_name: "LWS::Auth::Company" |
#company_id ⇒ Integer
Returns the ID of the company the collection belongs to.
68 |
# File 'lib/lws/apps/resource.rb', line 68 attribute :company_id |
#deleted_at ⇒ String?
Returns the timestamp of when the collection was deleted.
72 |
# File 'lib/lws/apps/resource.rb', line 72 attribute :deleted_at |
#description ⇒ String
Returns the description of the collection.
76 |
# File 'lib/lws/apps/resource.rb', line 76 attribute :description |
#email ⇒ String?
Returns the email address used for email imports.
80 |
# File 'lib/lws/apps/resource.rb', line 80 attribute :email |
#folder ⇒ Folder
Returns the folder that the collection is filed in.
84 |
# File 'lib/lws/apps/resource.rb', line 84 belongs_to :folder |
#folder_id ⇒ Integer
Returns the ID of the folder that the collection is filed in.
89 |
# File 'lib/lws/apps/resource.rb', line 89 attribute :folder_id |
#item_ids ⇒ Array<Integer>
Returns the ID of the items that are part of the collection.
94 |
# File 'lib/lws/apps/resource.rb', line 94 attribute :item_ids |
#items ⇒ Array<Collection::Item>
The returned cllection item (sub)class that is determined by the kind of this collection.
102 |
# File 'lib/lws/apps/resource.rb', line 102 has_many :items, class_name: "LWS::Resource::Collection::Item" |
#kind ⇒ "feed", ...
Returns the name of the class/kind of the collection.
107 |
# File 'lib/lws/apps/resource.rb', line 107 attribute :kind |
#name ⇒ String
Returns the name of the collection.
111 |
# File 'lib/lws/apps/resource.rb', line 111 attribute :name |
#preview_url ⇒ String
Returns the URL of a preview of the collection.
115 |
# File 'lib/lws/apps/resource.rb', line 115 attribute :preview_url |
#processing ⇒ Boolean
Returns whether the collection is being processed (i.e. it is not ready for use).
120 |
# File 'lib/lws/apps/resource.rb', line 120 attribute :processing |
#uuid ⇒ String
Returns the UUID used for unique file name generation.
124 |
# File 'lib/lws/apps/resource.rb', line 124 attribute :uuid |