-
Notifications
You must be signed in to change notification settings - Fork 25
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Implemented fetching list of all custom events
- Loading branch information
Showing
4 changed files
with
69 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
require 'fabricio/models/abstract_model' | ||
|
||
module Fabricio | ||
module Model | ||
# This model represents a custom event type | ||
class CustomEventType < AbstractModel | ||
attr_reader :type, :key, :count | ||
|
||
# Returns a CustomEventType model object | ||
# | ||
# @param attributes [Hash] | ||
# @return [Fabricio::Model::CustomEventType] | ||
def initialize(attributes) | ||
@type = attributes['event_type'] | ||
@count = attributes['event_count'] | ||
@key = attributes['event_key'] | ||
@json = attributes | ||
end | ||
end | ||
end | ||
end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters