import Foundation public enum AnalyticsEvent { <%- for @event in @events -%> case .<%= @event.name %> <%- end -%> public var name: String { switch self { <%- for @event in @events -%> case .<%= @event.name %>: return "<%= @event.name %>" <%- end -%> } } public var params: [String:String]? { switch self { <%- for @event in @events -%> <%- if @event.params.nil? -%> case .<%= @event.name %>: return nil <%- else -%> case .<%= @event.name %>: return <%= @event.params_for(:ios) %> <%- end -%> <%- end -%> } } }