class Yt::Models::RightOwner
Encapsulates information about the various types of owners of an asset. @see developers.google.com/youtube/partner/docs/v1/ownership#resource
Public Class Methods
Source
# File lib/yt/models/right_owner.rb, line 6 def initialize(options = {}) @data = options[:data] end
Public Instance Methods
Source
# File lib/yt/models/right_owner.rb, line 46 def everywhere? excluded_territories == [] end
@return [Boolean] whether the ownership applies to the whole world.
Source
# File lib/yt/models/right_owner.rb, line 41 def excluded_territories territories if type == 'exclude' end
Return the list of territories where the owner does not own the asset. Each territory is an ISO 3166 two-letter country code. @return [Array<String>] if the ownership lists ‘excluded’ territories,
the territories where the owner does not own the asset.
@return [nil] if the ownership does not list ‘excluded’ territories,
Source
# File lib/yt/models/right_owner.rb, line 32 def included_territories territories if type == 'include' end
Return the list of territories where the owner owns the asset. Each territory is an ISO 3166 two-letter country code. @return [Array<String>] if the ownership lists ‘included’ territories,
the territories where the owner owns the asset.
@return [nil] if the ownership does not list ‘included’ territories,