Class: Array
Instance Method Summary
collapse
#<
#<=
#===, #old_triple_equal4Set
#to_set
#**
#^
Instance Method Details
#&(item) ⇒ Object
649
650
651
652
653
654
|
# File 'lib/setfu.rb', line 649
def &(item)
return old_and_method4set(item) if (item.class==Array)
a = Set.new(self)
b = Set.new(item)
return a & b
end
|
#-(item) ⇒ Object
643
644
645
646
647
648
|
# File 'lib/setfu.rb', line 643
def -(item)
return old_subtract_method4set(item) if (item.class==Array)
a = Set.new(self)
b = Set.new(item)
return a - b
end
|
#old_and_method4set ⇒ Object
633
|
# File 'lib/setfu.rb', line 633
alias_method :old_and_method4set, :&
|
#old_or_method4set ⇒ Object
634
|
# File 'lib/setfu.rb', line 634
alias_method :old_or_method4set, :|
|
#old_subtract_method4set ⇒ Object
632
|
# File 'lib/setfu.rb', line 632
alias_method :old_subtract_method4set, :-
|
#|(item) ⇒ Object
655
656
657
658
659
660
|
# File 'lib/setfu.rb', line 655
def |(item)
return old_or_method4set(item) if (item.class==Array)
a = Set.new(self)
b = Set.new(item)
return a | b
end
|