Class: Card::Set::Rule

Inherits:
Pattern::Base show all
Defined in:
platypus/tmp/set_pattern/105-rule.rb,
platypus/tmp/set/gem-defaults/mod010-rules/rule/rules.rb,
platypus/tmp/set/gem-defaults/mod010-rules/rule/editor.rb,
platypus/tmp/set/gem-defaults/mod010-rules/rule/bar_view.rb,
platypus/tmp/set/gem-defaults/mod010-rules/rule/rule_form.rb,
platypus/tmp/set/gem-defaults/mod010-rules/rule/html_views.rb,
platypus/tmp/set/gem-defaults/mod010-rules/rule/quick_editor.rb,
platypus/tmp/set/gem-defaults/mod010-rules/rule/rule_form/buttons.rb,
platypus/tmp/set/gem-defaults/mod010-rules/rule/board_rules_editor.rb,
platypus/tmp/set/gem-defaults/mod010-rules/rule/rule_form/set_selection.rb,
platypus/tmp/set/gem-defaults/mod010-rules/rule/rule_form/rule_set_radio.rb

Overview

Set Pattern: Rule

Defined Under Namespace

Modules: BarView, BoardRulesEditor, Editor, HtmlViews, QuickEditor, RuleForm, Rules

Constant Summary collapse

@@options =
{ compound_only: true }

Instance Attribute Summary

Attributes included from Pattern::ClassMethods

#anchor_parts_count, #anchorless, #assigns_type, #compound_only, #pattern_code

Class Method Summary collapse

Methods inherited from Pattern::Base

#anchor_codenames, #anchor_parts, #find_anchor_id, #format_module_list, #initialize, #inspect, #lookup_module_list, #module_key, #module_list, #rule_lookup_key, #safe_key, #to_s

Methods included from Pattern::ClassMethods

#anchorless?, #compound_only?, #generic_label, #module_key, #new, #pattern, #pattern_applies?, #pattern_id, #register

Constructor Details

This class inherits a constructor from Card::Set::Pattern::Base

Class Method Details

.label(_name) ⇒ Object



9
10
11
# File 'platypus/tmp/set_pattern/105-rule.rb', line 9

def label _name
  "All rule cards"
end

.pattern_applies?(card) ⇒ Boolean

Returns:

  • (Boolean)


21
22
23
# File 'platypus/tmp/set_pattern/105-rule.rb', line 21

def pattern_applies? card
  card.rule?
end

.prototype_args(_anchor) ⇒ Object



17
18
19
# File 'platypus/tmp/set_pattern/105-rule.rb', line 17

def prototype_args _anchor
  { name: "*all+*create" }
end

.short_label(_name) ⇒ Object



13
14
15
# File 'platypus/tmp/set_pattern/105-rule.rb', line 13

def short_label _name
  "all rule cards"
end