Class: PubgRb::Profile

Inherits:
Object
  • Object
show all
Defined in:
lib/pubg_rb/profile.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(opts = {}) ⇒ Profile

Returns a new instance of Profile.



4
5
6
7
# File 'lib/pubg_rb/profile.rb', line 4

def initialize(opts={})
  opts.each { |k,v| instance_variable_set("@#{k.downcase}", v) }
  instance_variable_set("@lastupdated", DateTime.parse(self.lastupdated[0..18]))
end

Instance Attribute Details

#accountidObject (readonly)

Returns the value of attribute accountid.



3
4
5
# File 'lib/pubg_rb/profile.rb', line 3

def accountid
  @accountid
end

#avatarObject (readonly)

Returns the value of attribute avatar.



3
4
5
# File 'lib/pubg_rb/profile.rb', line 3

def avatar
  @avatar
end

#defaultseasonObject (readonly)

Returns the value of attribute defaultseason.



3
4
5
# File 'lib/pubg_rb/profile.rb', line 3

def defaultseason
  @defaultseason
end

#lastupdatedObject (readonly)

Returns the value of attribute lastupdated.



3
4
5
# File 'lib/pubg_rb/profile.rb', line 3

def lastupdated
  @lastupdated
end

#matchhistoryObject (readonly)

Returns the value of attribute matchhistory.



3
4
5
# File 'lib/pubg_rb/profile.rb', line 3

def matchhistory
  @matchhistory
end

#platformidObject (readonly)

Returns the value of attribute platformid.



3
4
5
# File 'lib/pubg_rb/profile.rb', line 3

def platformid
  @platformid
end

#playernameObject (readonly)

Returns the value of attribute playername.



3
4
5
# File 'lib/pubg_rb/profile.rb', line 3

def playername
  @playername
end

#pubgtrackeridObject (readonly)

Returns the value of attribute pubgtrackerid.



3
4
5
# File 'lib/pubg_rb/profile.rb', line 3

def pubgtrackerid
  @pubgtrackerid
end

#seasondisplayObject (readonly)

Returns the value of attribute seasondisplay.



3
4
5
# File 'lib/pubg_rb/profile.rb', line 3

def seasondisplay
  @seasondisplay
end

#selectedregionObject (readonly)

Returns the value of attribute selectedregion.



3
4
5
# File 'lib/pubg_rb/profile.rb', line 3

def selectedregion
  @selectedregion
end

#statsObject (readonly)

Returns the value of attribute stats.



3
4
5
# File 'lib/pubg_rb/profile.rb', line 3

def stats
  @stats
end