Class: Geostats::Grabber::User
- Inherits:
-
Object
- Object
- Geostats::Grabber::User
- Defined in:
- lib/geostats/grabber/user.rb
Instance Method Summary collapse
-
#initialize(uuid) ⇒ User
constructor
A new instance of User.
- #username ⇒ Object
Constructor Details
#initialize(uuid) ⇒ User
Returns a new instance of User.
4 5 6 |
# File 'lib/geostats/grabber/user.rb', line 4 def initialize(uuid) @resp, @data = HTTP.get("/profile/?guid=#{uuid}") end |
Instance Method Details
#username ⇒ Object
8 9 10 11 12 |
# File 'lib/geostats/grabber/user.rb', line 8 def username if @data =~ /<h2><span id="ctl00_ContentBody_lblUserProfile".*?>Profile for User: (.*?)<\/span><\/h2>/ Utils.unescape($1) end end |