Class: RUTorrent::RSSFilter
- Inherits:
-
Object
- Object
- RUTorrent::RSSFilter
- Defined in:
- lib/rutorrent/rssfilter.rb
Constant Summary
- QUALITIES =
%w{HDTV
Instance Attribute Summary (collapse)
-
- (Object) directory
readonly
Returns the value of attribute directory.
-
- (Object) episode_filter
readonly
Returns the value of attribute episode_filter.
-
- (Object) episode_filter_str
readonly
Returns the value of attribute episode_filter_str.
-
- (Object) feed
readonly
Returns the value of attribute feed.
-
- (Object) filter
readonly
Returns the value of attribute filter.
-
- (Object) flags
readonly
Returns the value of attribute flags.
-
- (Object) id
readonly
Returns the value of attribute id.
-
- (Object) label
readonly
Returns the value of attribute label.
-
- (Object) last_match
readonly
Returns the value of attribute last_match.
-
- (Object) name
readonly
Returns the value of attribute name.
-
- (Object) not_filter
readonly
Returns the value of attribute not_filter.
-
- (Object) postpone_mode
readonly
Returns the value of attribute postpone_mode.
-
- (Object) quality
readonly
Returns the value of attribute quality.
-
- (Object) repack_ep_filter
readonly
Returns the value of attribute repack_ep_filter.
-
- (Object) resolving_candidate
readonly
Returns the value of attribute resolving_candidate.
-
- (Object) smart_ep_filter
readonly
Returns the value of attribute smart_ep_filter.
Instance Method Summary (collapse)
- - (Boolean) add_stopped?
- - (Boolean) enabled?
- - (Boolean) high_priority?
-
- (RSSFilter) initialize(array)
constructor
A new instance of RSSFilter.
- - (Boolean) matches_original_name?
- - (Object) qualities
- - (Boolean) smart_episode_filter?
Constructor Details
- (RSSFilter) initialize(array)
A new instance of RSSFilter
11 12 13 14 15 |
# File 'lib/rutorrent/rssfilter.rb', line 11 def initialize(array) @id, @flags, @name, @filter, @not_filter, @directory, @feed, @quality, @label, @postpone_mode, @last_match, @smart_ep_filter, @repack_ep_filter, @episode_filter_str, @episode_filter, @resolving_candidate = array end |
Instance Attribute Details
- (Object) directory (readonly)
Returns the value of attribute directory
6 7 8 |
# File 'lib/rutorrent/rssfilter.rb', line 6 def directory @directory end |
- (Object) episode_filter (readonly)
Returns the value of attribute episode_filter
6 7 8 |
# File 'lib/rutorrent/rssfilter.rb', line 6 def episode_filter @episode_filter end |
- (Object) episode_filter_str (readonly)
Returns the value of attribute episode_filter_str
6 7 8 |
# File 'lib/rutorrent/rssfilter.rb', line 6 def episode_filter_str @episode_filter_str end |
- (Object) feed (readonly)
Returns the value of attribute feed
6 7 8 |
# File 'lib/rutorrent/rssfilter.rb', line 6 def feed @feed end |
- (Object) filter (readonly)
Returns the value of attribute filter
6 7 8 |
# File 'lib/rutorrent/rssfilter.rb', line 6 def filter @filter end |
- (Object) flags (readonly)
Returns the value of attribute flags
6 7 8 |
# File 'lib/rutorrent/rssfilter.rb', line 6 def flags @flags end |
- (Object) id (readonly)
Returns the value of attribute id
6 7 8 |
# File 'lib/rutorrent/rssfilter.rb', line 6 def id @id end |
- (Object) label (readonly)
Returns the value of attribute label
6 7 8 |
# File 'lib/rutorrent/rssfilter.rb', line 6 def label @label end |
- (Object) last_match (readonly)
Returns the value of attribute last_match
6 7 8 |
# File 'lib/rutorrent/rssfilter.rb', line 6 def last_match @last_match end |
- (Object) name (readonly)
Returns the value of attribute name
6 7 8 |
# File 'lib/rutorrent/rssfilter.rb', line 6 def name @name end |
- (Object) not_filter (readonly)
Returns the value of attribute not_filter
6 7 8 |
# File 'lib/rutorrent/rssfilter.rb', line 6 def not_filter @not_filter end |
- (Object) postpone_mode (readonly)
Returns the value of attribute postpone_mode
6 7 8 |
# File 'lib/rutorrent/rssfilter.rb', line 6 def postpone_mode @postpone_mode end |
- (Object) quality (readonly)
Returns the value of attribute quality
6 7 8 |
# File 'lib/rutorrent/rssfilter.rb', line 6 def quality @quality end |
- (Object) repack_ep_filter (readonly)
Returns the value of attribute repack_ep_filter
6 7 8 |
# File 'lib/rutorrent/rssfilter.rb', line 6 def repack_ep_filter @repack_ep_filter end |
- (Object) resolving_candidate (readonly)
Returns the value of attribute resolving_candidate
6 7 8 |
# File 'lib/rutorrent/rssfilter.rb', line 6 def resolving_candidate @resolving_candidate end |
- (Object) smart_ep_filter (readonly)
Returns the value of attribute smart_ep_filter
6 7 8 |
# File 'lib/rutorrent/rssfilter.rb', line 6 def smart_ep_filter @smart_ep_filter end |
Instance Method Details
- (Boolean) add_stopped?
21 |
# File 'lib/rutorrent/rssfilter.rb', line 21 def add_stopped?; !@flags[4].zero? end |
- (Boolean) enabled?
17 |
# File 'lib/rutorrent/rssfilter.rb', line 17 def enabled?; !@flags[0].zero? end |
- (Boolean) high_priority?
19 |
# File 'lib/rutorrent/rssfilter.rb', line 19 def high_priority?; !@flags[2].zero? end |
- (Boolean) matches_original_name?
18 |
# File 'lib/rutorrent/rssfilter.rb', line 18 def matches_original_name?; !@flags[1].zero? end |
- (Object) qualities
23 24 25 26 27 28 29 30 31 32 |
# File 'lib/rutorrent/rssfilter.rb', line 23 def qualities unless @qualities @qualities = [] QUALITIES.each_with_index do |q,i| @qualities << q unless @quality[i].zero? end end @qualities end |
- (Boolean) smart_episode_filter?
20 |
# File 'lib/rutorrent/rssfilter.rb', line 20 def smart_episode_filter?; !@flags[3].zero? end |