Class: ElasticAPM::Normalizers::Collection Private

Inherits:
Object
  • Object
show all
Defined in:
lib/elastic_apm/normalizers.rb

This class is part of a private API. You should avoid using this class if possible, as it may be removed or be changed in the future.

Defined Under Namespace

Classes: SkipNormalizer

Instance Method Summary collapse

Constructor Details

#initialize(normalizers) ⇒ Collection

This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.

Returns a new instance of Collection.



60
61
62
63
# File 'lib/elastic_apm/normalizers.rb', line 60

def initialize(normalizers)
  @normalizers = normalizers
  @default = SkipNormalizer.new
end

Instance Method Details

#backtrace(name, payload) ⇒ Object

This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.



77
78
79
# File 'lib/elastic_apm/normalizers.rb', line 77

def backtrace(name, payload)
  self.for(name).backtrace(payload)
end

#for(name) ⇒ Object

This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.



65
66
67
# File 'lib/elastic_apm/normalizers.rb', line 65

def for(name)
  @normalizers.fetch(name) { @default }
end

#keysObject

This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.



69
70
71
# File 'lib/elastic_apm/normalizers.rb', line 69

def keys
  @normalizers.keys
end

#normalize(transaction, name, payload) ⇒ Object

This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.



73
74
75
# File 'lib/elastic_apm/normalizers.rb', line 73

def normalize(transaction, name, payload)
  self.for(name).normalize(transaction, name, payload)
end