Class: GHArchive::MemberEvent

Inherits:
Event
  • Object
show all
Defined in:
lib/gh-archive/events.rb

Constant Summary

Constants inherited from Event

Event::IMPLEMENTATIONS

Class Method Summary collapse

Instance Method Summary collapse

Methods inherited from Event

#actor, #created_at, #initialize, #json, parse, #public?, #repo

Constructor Details

This class inherits a constructor from GHArchive::Event

Class Method Details

.fits?(json) ⇒ Boolean

Returns:

  • (Boolean)


379
380
381
# File 'lib/gh-archive/events.rb', line 379

def self.fits?(json)
    return json['type'] == "MemberEvent"
end

Instance Method Details

#actionObject



383
384
385
# File 'lib/gh-archive/events.rb', line 383

def action
    @payload['action']
end

#memberObject



387
388
389
# File 'lib/gh-archive/events.rb', line 387

def member
    User.new(@payload['member'])
end