Class: Amnesie::Network

Inherits:
Object
  • Object
show all
Defined in:
lib/amnesie/network.rb

Instance Method Summary collapse

Constructor Details

#initialize(card_match, name = nil) ⇒ Network

Returns a new instance of Network.


5
6
7
8
9
10
# File 'lib/amnesie/network.rb', line 5

def initialize(card_match, name = nil)
  @card_match = card_match
  @name = name
  @devs = []
  @check = false
end

Instance Method Details

#searchObject


12
13
14
15
16
17
18
19
20
# File 'lib/amnesie/network.rb', line 12

def search
  if @name
    verify_card
    @devs << @name
  else
    search_cards
    @devs
  end
end