Class: PostmonRuby::Finders::Tracker::ECTTrackerFinder

Inherits:
Finder
  • Object
show all
Defined in:
lib/postmon_ruby/finders/tracker/ect_tracker_finder.rb

Instance Method Summary collapse

Methods inherited from Finder

#arguments_uri

Instance Method Details

#arguments_sizeObject



9
10
11
# File 'lib/postmon_ruby/finders/tracker/ect_tracker_finder.rb', line 9

def arguments_size
  1
end

#endpointObject



5
6
7
# File 'lib/postmon_ruby/finders/tracker/ect_tracker_finder.rb', line 5

def endpoint
  "rastreio/ect"
end

#search(*arguments) ⇒ Object



13
14
15
16
# File 'lib/postmon_ruby/finders/tracker/ect_tracker_finder.rb', line 13

def search(*arguments)
  arguments.flatten!
  PostmonRuby::Track.new( HTTParty.get(self.arguments_uri(arguments)) )
end